Title: [260968] trunk
Revision
260968
Author
[email protected]
Date
2020-04-30 14:39:06 -0700 (Thu, 30 Apr 2020)

Log Message

Change default of "inAppBrowserPrivacyQuirks" testing toggle to use it for tests only
https://bugs.webkit.org/show_bug.cgi?id=211209
<rdar://problem/62619659>

Reviewed by Brent Fulgham.

Source/WebKit:

No new tests, behavior confirmed by existing tests.

* Shared/WebPreferences.yaml:

Tools:

Manually enable inAppBrowserPrivacyQuirks for certain tests which
need script evaluation to test other aspects of In-App Browser Privacy.

* TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm:
(TEST):

Modified Paths

Diff

Modified: trunk/Source/WebKit/ChangeLog (260967 => 260968)


--- trunk/Source/WebKit/ChangeLog	2020-04-30 21:28:08 UTC (rev 260967)
+++ trunk/Source/WebKit/ChangeLog	2020-04-30 21:39:06 UTC (rev 260968)
@@ -1,3 +1,15 @@
+2020-04-30  Kate Cheney  <[email protected]>
+
+        Change default of "inAppBrowserPrivacyQuirks" testing toggle to use it for tests only
+        https://bugs.webkit.org/show_bug.cgi?id=211209
+        <rdar://problem/62619659>
+
+        Reviewed by Brent Fulgham.
+
+        No new tests, behavior confirmed by existing tests.
+
+        * Shared/WebPreferences.yaml:
+
 2020-04-30  Devin Rousso  <[email protected]>
 
         Unreviewed, add missing parenthesis

Modified: trunk/Source/WebKit/Shared/WebPreferences.yaml (260967 => 260968)


--- trunk/Source/WebKit/Shared/WebPreferences.yaml	2020-04-30 21:28:08 UTC (rev 260967)
+++ trunk/Source/WebKit/Shared/WebPreferences.yaml	2020-04-30 21:39:06 UTC (rev 260968)
@@ -1275,7 +1275,7 @@
 
 NeedsInAppBrowserPrivacyQuirks:
     type: bool
-    defaultValue: true
+    defaultValue: false
     humanReadableName: "Needs In-App Browser Privacy Quirks"
     humanReadableDescription: "Enable quirks needed to support In-App Browser privacy"
     webcoreBinding: RuntimeEnabledFeatures

Modified: trunk/Tools/ChangeLog (260967 => 260968)


--- trunk/Tools/ChangeLog	2020-04-30 21:28:08 UTC (rev 260967)
+++ trunk/Tools/ChangeLog	2020-04-30 21:39:06 UTC (rev 260968)
@@ -1,3 +1,17 @@
+2020-04-30  Kate Cheney  <[email protected]>
+
+        Change default of "inAppBrowserPrivacyQuirks" testing toggle to use it for tests only
+        https://bugs.webkit.org/show_bug.cgi?id=211209
+        <rdar://problem/62619659>
+
+        Reviewed by Brent Fulgham.
+
+        Manually enable inAppBrowserPrivacyQuirks for certain tests which
+        need script evaluation to test other aspects of In-App Browser Privacy.
+
+        * TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm:
+        (TEST):
+
 2020-04-30  Jonathan Bedard  <[email protected]>
 
         results.webkit.org: Sort out certificates on Catalina

Modified: trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm (260967 => 260968)


--- trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm	2020-04-30 21:28:08 UTC (rev 260967)
+++ trunk/Tools/TestWebKitAPI/Tests/WebKitCocoa/InAppBrowserPrivacy.mm	2020-04-30 21:39:06 UTC (rev 260968)
@@ -330,6 +330,7 @@
     auto schemeHandler = adoptNS([[InAppBrowserSchemeHandler alloc] init]);
     [configuration setURLSchemeHandler:schemeHandler.get() forURLScheme:@"in-app-browser"];
     [[configuration preferences] _setInAppBrowserPrivacyEnabled:YES];
+    [[configuration preferences] _setNeedsInAppBrowserPrivacyQuirks:YES];
 
     auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectZero configuration:configuration.get()]);
     NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"in-app-browser:///in-app-browser-privacy-test-user-style-sheets"]];
@@ -353,6 +354,7 @@
     auto schemeHandler = adoptNS([[InAppBrowserSchemeHandler alloc] init]);
     [configuration setURLSchemeHandler:schemeHandler.get() forURLScheme:@"in-app-browser"];
     [[configuration preferences] _setInAppBrowserPrivacyEnabled:YES];
+    [[configuration preferences] _setNeedsInAppBrowserPrivacyQuirks:YES];
 
     auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectZero configuration:configuration.get()]);
     NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"in-app-browser:///in-app-browser-privacy-test-user-style-sheets"]];
@@ -375,6 +377,7 @@
     auto schemeHandler = adoptNS([[InAppBrowserSchemeHandler alloc] init]);
     [configuration setURLSchemeHandler:schemeHandler.get() forURLScheme:@"in-app-browser"];
     [[configuration preferences] _setInAppBrowserPrivacyEnabled:YES];
+    [[configuration preferences] _setNeedsInAppBrowserPrivacyQuirks:YES];
 
     auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectZero configuration:configuration.get()]);
     NSURLRequest *request = [NSURLRequest requestWithURL:[NSURL URLWithString:@"in-app-browser:///in-app-browser-privacy-test-user-style-sheets-iframe"]];
@@ -402,6 +405,7 @@
     auto schemeHandler = adoptNS([[InAppBrowserSchemeHandler alloc] init]);
     [configuration setURLSchemeHandler:schemeHandler.get() forURLScheme:@"in-app-browser"];
     [[configuration preferences] _setInAppBrowserPrivacyEnabled:YES];
+    [[configuration preferences] _setNeedsInAppBrowserPrivacyQuirks:YES];
 
     auto webView = adoptNS([[TestWKWebView alloc] initWithFrame:CGRectZero configuration:configuration.get()]);
 
@@ -987,7 +991,9 @@
     TestWebKitAPI::Util::run(&isDone);
 
     // Navigation should be successful, but this WebView should not get app-bound domain
-    // privileges like user style sheets.
+    // privileges like user style sheets. Set quirks to true so we can evaluate script
+    // to check.
+    [[[webView configuration] preferences] _setNeedsInAppBrowserPrivacyQuirks:YES];
     expectScriptEvaluatesToColor(webView.get(), backgroundColorScript, blackInRGB);
     cleanUpInAppBrowserPrivacyTestSettings();
 }
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to