Title: [220179] trunk
Revision
220179
Author
[email protected]
Date
2017-08-02 21:19:10 -0700 (Wed, 02 Aug 2017)

Log Message

HTTP tests with 'https' suffix are only run over HTTPS for WK2, not WK1
https://bugs.webkit.org/show_bug.cgi?id=175089

Patch by Youenn Fablet <[email protected]> on 2017-08-02
Reviewed by Chris Dumez.

Tools:

* DumpRenderTree/TestOptions.mm:
(TestOptions::TestOptions): Using absolutePath if available.
* DumpRenderTree/mac/DumpRenderTree.mm:
(computeTestURL): Removing http/tests/ specific URL computation.
* Scripts/webkitpy/port/driver.py:
(Driver._command_from_driver_input): Making webkitpy passing HTTP urls for HTTP served tests to all test runners, including WK1.

LayoutTests:

Removing no longer needed expectations.

* platform/ios-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt: Removed.
* platform/mac-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt: Removed.

Modified Paths

Removed Paths

Diff

Modified: trunk/LayoutTests/ChangeLog (220178 => 220179)


--- trunk/LayoutTests/ChangeLog	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/LayoutTests/ChangeLog	2017-08-03 04:19:10 UTC (rev 220179)
@@ -1,3 +1,15 @@
+2017-08-02  Youenn Fablet  <[email protected]>
+
+        HTTP tests with 'https' suffix are only run over HTTPS for WK2, not WK1
+        https://bugs.webkit.org/show_bug.cgi?id=175089
+
+        Reviewed by Chris Dumez.
+
+        Removing no longer needed expectations.
+
+        * platform/ios-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt: Removed.
+        * platform/mac-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt: Removed.
+
 2017-08-02  Matt Lewis  <[email protected]>
 
         Marked http/tests/appcache/deferred-events-delete-while-raising-timer.html as flaky.

Deleted: trunk/LayoutTests/platform/ios-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt (220178 => 220179)


--- trunk/LayoutTests/platform/ios-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/LayoutTests/platform/ios-wk1/http/tests/security/contentSecurityPolicy/upgrade-insecure-requests/iframe-upgrade.https-expected.txt	2017-08-03 04:19:10 UTC (rev 220179)
@@ -1,6 +0,0 @@
-
-
-PASS Same-host frames are upgraded. 
-PASS Cross-host frames are upgraded. 
-PASS Upgrade policy does NOT cascade to nested, cross-host frames. 
-

Modified: trunk/Tools/ChangeLog (220178 => 220179)


--- trunk/Tools/ChangeLog	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/Tools/ChangeLog	2017-08-03 04:19:10 UTC (rev 220179)
@@ -1,3 +1,17 @@
+2017-08-02  Youenn Fablet  <[email protected]>
+
+        HTTP tests with 'https' suffix are only run over HTTPS for WK2, not WK1
+        https://bugs.webkit.org/show_bug.cgi?id=175089
+
+        Reviewed by Chris Dumez.
+
+        * DumpRenderTree/TestOptions.mm:
+        (TestOptions::TestOptions): Using absolutePath if available.
+        * DumpRenderTree/mac/DumpRenderTree.mm:
+        (computeTestURL): Removing http/tests/ specific URL computation.
+        * Scripts/webkitpy/port/driver.py:
+        (Driver._command_from_driver_input): Making webkitpy passing HTTP urls for HTTP served tests to all test runners, including WK1.
+
 2017-08-02  Lucas Forschler  <[email protected]>
 
         download-built-product should allow for a proxy option

Modified: trunk/Tools/DumpRenderTree/TestOptions.mm (220178 => 220179)


--- trunk/Tools/DumpRenderTree/TestOptions.mm	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/Tools/DumpRenderTree/TestOptions.mm	2017-08-03 04:19:10 UTC (rev 220179)
@@ -44,14 +44,12 @@
 TestOptions::TestOptions(NSURL *testURL, const TestCommand& command)
 {
     std::string path = command.absolutePath;
-    if (path.empty() && [testURL isFileURL])
-        path = [testURL fileSystemRepresentation];
-    else
-        path = command.pathOrURL;
+    if (path.empty()) {
+        path = [testURL isFileURL] ? [testURL fileSystemRepresentation] : command.pathOrURL;
+        if (path.empty())
+            return;
+    }
 
-    if (path.empty())
-        return;
-
     std::string options;
     std::ifstream testFile(path.data());
     if (!testFile.good())

Modified: trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm (220178 => 220179)


--- trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/Tools/DumpRenderTree/mac/DumpRenderTree.mm	2017-08-03 04:19:10 UTC (rev 220179)
@@ -1907,28 +1907,7 @@
         return [NSURL fileURLWithPath:absolutePath];
 
     *relativeTestPath = [absolutePath substringFromIndex:NSMaxRange(layoutTestsRange)];
-
-    // Convert file URLs in LayoutTests/http/tests to HTTP URLs, except for file URLs in LayoutTests/http/tests/local.
-
-    NSRange httpTestsRange = [absolutePath rangeOfString:@"/LayoutTests/http/tests/"];
-    if (httpTestsRange.location == NSNotFound || [absolutePath rangeOfString:@"/LayoutTests/http/tests/local/"].location != NSNotFound)
-        return [NSURL fileURLWithPath:absolutePath];
-
-    auto components = adoptNS([[NSURLComponents alloc] init]);
-    [components setPath:[absolutePath substringFromIndex:NSMaxRange(httpTestsRange) - 1]];
-    [components setHost:@"127.0.0.1"];
-
-    // Paths under /ssl/ should be loaded using HTTPS.
-    BOOL isSecure = [[components path] hasPrefix:@"/ssl/"];
-    if (isSecure) {
-        [components setScheme:@"https"];
-        [components setPort:@(8443)];
-    } else {
-        [components setScheme:@"http"];
-        [components setPort:@(8000)];
-    }
-
-    return [components URL];
+    return [NSURL fileURLWithPath:absolutePath];
 }
 
 static void runTest(const string& inputLine)

Modified: trunk/Tools/Scripts/webkitpy/port/driver.py (220178 => 220179)


--- trunk/Tools/Scripts/webkitpy/port/driver.py	2017-08-03 03:53:05 UTC (rev 220178)
+++ trunk/Tools/Scripts/webkitpy/port/driver.py	2017-08-03 04:19:10 UTC (rev 220179)
@@ -485,7 +485,7 @@
         # FIXME: performance tests pass in full URLs instead of test names.
         if driver_input.test_name.startswith('http://') or driver_input.test_name.startswith('https://')  or driver_input.test_name == ('about:blank'):
             command = driver_input.test_name
-        elif self.is_web_platform_test(driver_input.test_name) or self.is_webkit_specific_web_platform_test(driver_input.test_name) or (self.is_http_test(driver_input.test_name) and (self._port.get_option('webkit_test_runner') or sys.platform == "cygwin")):
+        elif self.is_web_platform_test(driver_input.test_name) or self.is_webkit_specific_web_platform_test(driver_input.test_name) or self.is_http_test(driver_input.test_name):
             command = self.test_to_uri(driver_input.test_name)
             command += "'--absolutePath'"
             command += self._port.abspath_for_test(driver_input.test_name, self._target_host)
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to