Changeset 270598 in webkit
- Timestamp:
- Dec 9, 2020, 1:24:40 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 7 edited
-
LayoutTests/ChangeLog (modified) (1 diff)
-
LayoutTests/http/tests/privateClickMeasurement/expired-attribution-report-gets-sent-on-session-start-expected.txt (modified) (1 diff)
-
LayoutTests/http/tests/privateClickMeasurement/send-attribution-conversion-request-expected.txt (modified) (1 diff)
-
Source/WebCore/ChangeLog (modified) (1 diff)
-
Source/WebCore/loader/PrivateClickMeasurement.cpp (modified) (1 diff)
-
Tools/ChangeLog (modified) (1 diff)
-
Tools/TestWebKitAPI/Tests/WebCore/PrivateClickMeasurement.cpp (modified) (3 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/LayoutTests/ChangeLog
r270590 r270598 1 2020-12-09 John Wilander <wilander@apple.com> 2 3 PCM: Make JSON key names use underscores according to the W3C conversation 4 https://bugs.webkit.org/show_bug.cgi?id=219696 5 <rdar://problem/72143642> 6 7 Reviewed by Brent Fulgham. 8 9 Further discussion in https://github.com/privacycg/private-click-measurement/issues/30 10 concluded that the JSON report should use underscores in its keys instead of dashes. 11 This patch makes that change and shortens the "report_version" key to just "version". 12 13 * http/tests/privateClickMeasurement/expired-attribution-report-gets-sent-on-session-start-expected.txt: 14 * http/tests/privateClickMeasurement/send-attribution-conversion-request-expected.txt: 15 1 16 2020-12-09 Antti Koivisto <antti@apple.com> 2 17 -
trunk/LayoutTests/http/tests/privateClickMeasurement/expired-attribution-report-gets-sent-on-session-start-expected.txt
r270136 r270598 12 12 No cookies in attribution request. 13 13 Request body: 14 {"source -engagement-type":"click","source-site":"127.0.0.1","source-id":3,"attributed-on-site":"localhost","trigger-data":12,"report-version":1}14 {"source_engagement_type":"click","source_site":"127.0.0.1","source_id":3,"attributed_on_site":"localhost","trigger_data":12,"version":1} 15 15 16 16 -
trunk/LayoutTests/http/tests/privateClickMeasurement/send-attribution-conversion-request-expected.txt
r270136 r270598 17 17 No cookies in attribution request. 18 18 Request body: 19 {"source -engagement-type":"click","source-site":"127.0.0.1","source-id":3,"attributed-on-site":"localhost","trigger-data":12,"report-version":1}19 {"source_engagement_type":"click","source_site":"127.0.0.1","source_id":3,"attributed_on_site":"localhost","trigger_data":12,"version":1} 20 20 21 21 -
trunk/Source/WebCore/ChangeLog
r270597 r270598 1 2020-12-09 John Wilander <wilander@apple.com> 2 3 PCM: Make JSON key names use underscores according to the W3C conversation 4 https://bugs.webkit.org/show_bug.cgi?id=219696 5 <rdar://problem/72143642> 6 7 Reviewed by Brent Fulgham. 8 9 Further discussion in https://github.com/privacycg/private-click-measurement/issues/30 10 concluded that the JSON report should use underscores in its keys instead of dashes. 11 This patch makes that change and shortens the "report_version" key to just "version". 12 13 Existing tests updated. 14 15 * loader/PrivateClickMeasurement.cpp: 16 (WebCore::PrivateClickMeasurement::json const): 17 1 18 2020-12-09 Antoine Quint <graouts@webkit.org> 2 19 -
trunk/Source/WebCore/loader/PrivateClickMeasurement.cpp
r270456 r270598 161 161 return reportDetails; 162 162 163 reportDetails->setString("source -engagement-type"_s, "click"_s);164 reportDetails->setString("source -site"_s, m_sourceSite.registrableDomain.string());165 reportDetails->setInteger("source -id"_s, m_sourceID.id);166 reportDetails->setString("attributed -on-site"_s, m_attributeOnSite.registrableDomain.string());167 reportDetails->setInteger("trigger -data"_s, m_attributionTriggerData->data);168 reportDetails->setInteger(" report-version"_s, 1);163 reportDetails->setString("source_engagement_type"_s, "click"_s); 164 reportDetails->setString("source_site"_s, m_sourceSite.registrableDomain.string()); 165 reportDetails->setInteger("source_id"_s, m_sourceID.id); 166 reportDetails->setString("attributed_on_site"_s, m_attributeOnSite.registrableDomain.string()); 167 reportDetails->setInteger("trigger_data"_s, m_attributionTriggerData->data); 168 reportDetails->setInteger("version"_s, 1); 169 169 return reportDetails; 170 170 } -
trunk/Tools/ChangeLog
r270592 r270598 1 2020-12-09 John Wilander <wilander@apple.com> 2 3 PCM: Make JSON key names use underscores according to the W3C conversation 4 https://bugs.webkit.org/show_bug.cgi?id=219696 5 <rdar://problem/72143642> 6 7 Reviewed by Brent Fulgham. 8 9 Further discussion in https://github.com/privacycg/private-click-measurement/issues/30 10 concluded that the JSON report should use underscores in its keys instead of dashes. 11 This patch makes that change and shortens the "report_version" key to just "version". 12 13 * TestWebKitAPI/Tests/WebCore/PrivateClickMeasurement.cpp: 14 (TestWebKitAPI::TEST): 15 1 16 2020-12-09 Alex Christensen <achristensen@webkit.org> 2 17 -
trunk/Tools/TestWebKitAPI/Tests/WebCore/PrivateClickMeasurement.cpp
r270456 r270598 51 51 ASSERT_EQ(attributionURL.string(), "https://webkit.org/.well-known/private-click-measurement/"); 52 52 53 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source -engagement-type\":\"click\",\"source-site\":\"webkit.org\",\"source-id\":0,\"attributed-on-site\":\"example.com\",\"trigger-data\":0,\"report-version\":1}");53 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source_engagement_type\":\"click\",\"source_site\":\"webkit.org\",\"source_id\":0,\"attributed_on_site\":\"example.com\",\"trigger_data\":0,\"version\":1}"); 54 54 } 55 55 … … 63 63 ASSERT_EQ(attributionURL.string(), "https://webkit.org/.well-known/private-click-measurement/"); 64 64 65 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source -engagement-type\":\"click\",\"source-site\":\"webkit.org\",\"source-id\":192,\"attributed-on-site\":\"example.com\",\"trigger-data\":9,\"report-version\":1}");65 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source_engagement_type\":\"click\",\"source_site\":\"webkit.org\",\"source_id\":192,\"attributed_on_site\":\"example.com\",\"trigger_data\":9,\"version\":1}"); 66 66 } 67 67 … … 75 75 ASSERT_EQ(attributionURL.string(), "https://webkit.org/.well-known/private-click-measurement/"); 76 76 77 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source -engagement-type\":\"click\",\"source-site\":\"webkit.org\",\"source-id\":255,\"attributed-on-site\":\"example.com\",\"trigger-data\":15,\"report-version\":1}");77 ASSERT_EQ(attribution.json()->toJSONString(), "{\"source_engagement_type\":\"click\",\"source_site\":\"webkit.org\",\"source_id\":255,\"attributed_on_site\":\"example.com\",\"trigger_data\":15,\"version\":1}"); 78 78 } 79 79
Note:
See TracChangeset
for help on using the changeset viewer.