Esempio n. 1
0
 def test_test_to_uri(self):
     port = self.make_port()
     driver = Driver(port, None, pixel_tests=False)
     self.assertEqual(driver.test_to_uri('foo/bar.html'), 'file://%s/foo/bar.html' % port.layout_tests_dir())
     self.assertEqual(driver.test_to_uri('http/tests/foo.html'), 'http://127.0.0.1:8000/foo.html')
     self.assertEqual(driver.test_to_uri('http/tests/https/bar.html'), 'https://127.0.0.1:8443/https/bar.html')
     self.assertEqual(driver.test_to_uri('http/tests/bar.https.html'), 'https://127.0.0.1:8443/bar.https.html')
     self.assertEqual(driver.test_to_uri('http/tests/barhttps.html'), 'http://127.0.0.1:8000/barhttps.html')
Esempio n. 2
0
 def test_test_to_uri(self):
     port = self.make_port()
     driver = Driver(port, None)
     self.assertEqual(driver.test_to_uri('foo/bar.html'), 'file://%s/foo/bar.html' % port.web_tests_dir())
     self.assertEqual(driver.test_to_uri('http/tests/foo.html'), 'http://127.0.0.1:8000/foo.html')
     self.assertEqual(driver.test_to_uri('http/tests/https/bar.html'), 'https://127.0.0.1:8443/https/bar.html')
     self.assertEqual(driver.test_to_uri('http/tests/bar.https.html'), 'https://127.0.0.1:8443/bar.https.html')
     self.assertEqual(driver.test_to_uri('http/tests/barhttps.html'), 'http://127.0.0.1:8000/barhttps.html')
     self.assertEqual(driver.test_to_uri('external/wpt/foo/bar.html'),
                      'http://web-platform.test:8001/foo/bar.html')
     self.assertEqual(driver.test_to_uri('external/wpt/foo/bar.https.html'),
                      'https://web-platform.test:8444/foo/bar.https.html')
     self.assertEqual(driver.test_to_uri('external/wpt/foo/bar.serviceworker.html'),
                      'https://web-platform.test:8444/foo/bar.serviceworker.html')
     self.assertEqual(driver.test_to_uri('wpt_internal/foo/bar.html'),
                      'http://web-platform.test:8001/wpt_internal/foo/bar.html')
     self.assertEqual(driver.test_to_uri('wpt_internal/foo/bar.https.html'),
                      'https://web-platform.test:8444/wpt_internal/foo/bar.https.html')
     self.assertEqual(driver.test_to_uri('wpt_internal/foo/bar.serviceworker.html'),
                      'https://web-platform.test:8444/wpt_internal/foo/bar.serviceworker.html')