tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

commit eb69b35ec932f9e6df4d55373f8f37123826992f
parent 44259dece55fa8fedc63046ea021f09f8855be0a
Author: Chris Dumez <cdumez@apple.com>
Date:   Thu,  6 Nov 2025 21:36:05 +0000

Bug 1997874 [wpt PR 55823] - Fix navigate-anchor-cross-origin.html so it properly runs with Web…, a=testonly

Automatic update from web-platform-tests
Fix navigate-anchor-cross-origin.html so it properly runs with WebKit infrastructure (#55823)

The WebKit infrastructure rejects all non-local loads in tests. This test was trying to
load "https://does-not-exist/foo.html", which is not local.

Since the test simply wants to load a cross-origin URL, I am updating the test to load
`get_host_info().HTTPS_REMOTE_ORIGIN + "/does-not-exist.html"` which is cross-origin
and does not exist. It should not change the behavior of the test.

This is upstreaming from WebKit https://github.com/WebKit/WebKit/pull/53320.
--

wpt-commits: f2f2b918669faadeb1ec4b3e96f0bf2227991f96
wpt-pr: 55823

Diffstat:
Mtesting/web-platform/tests/navigation-api/navigate-event/navigate-anchor-cross-origin.html | 6++++--
1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/testing/web-platform/tests/navigation-api/navigate-event/navigate-anchor-cross-origin.html b/testing/web-platform/tests/navigation-api/navigate-event/navigate-anchor-cross-origin.html @@ -1,7 +1,8 @@ <!doctype html> <script src="/resources/testharness.js"></script> <script src="/resources/testharnessreport.js"></script> -<a id="a" href="https://does-not-exist/foo.html"></a> +<script src="/common/get-host-info.sub.js"></script> +<a id="a"></a> <script> async_test(t => { navigation.onnavigate = t.step_func_done(e => { @@ -12,7 +13,7 @@ async_test(t => { assert_false(e.hashChange); assert_equals(e.formData, null); assert_equals(e.downloadRequest, null); - assert_equals(e.destination.url, "https://does-not-exist/foo.html"); + assert_equals(e.destination.url, a.href); assert_false(e.destination.sameDocument); assert_equals(e.destination.key, ""); assert_equals(e.destination.id, ""); @@ -20,6 +21,7 @@ async_test(t => { assert_equals(e.sourceElement, document.getElementById("a")); e.preventDefault(); }); + a.href = get_host_info().HTTPS_REMOTE_ORIGIN + "/does-not-exist.html"; a.click(); }, "<a> cross-origin navigate event"); </script>