tor-browser

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

commit 078bcfa22f6008eb56e6443439087040623cae49
parent d673d427dbcc3d3ffce56526cacc4b056fa1d973
Author: Mike West <mkwst@chromium.org>
Date:   Mon, 10 Nov 2025 22:19:28 +0000

Bug 1998956 [wpt PR 55938] - [Origin API] Verify that comparisons are schemeful., a=testonly

Automatic update from web-platform-tests
[Origin API] Verify that comparisons are schemeful.

https://github.com/whatwg/html/pull/11846#discussion_r2500197421 noted
that we should verify schemeful same-site comparison; this CL adds that
test.

Bug: 434131026
Change-Id: I48878979fc0f8c3dab2caefbe788a14d367e053b
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/7130621
Reviewed-by: Antonio Sartori <antoniosartori@chromium.org>
Commit-Queue: Mike West <mkwst@chromium.org>
Cr-Commit-Position: refs/heads/main@{#1541759}

--

wpt-commits: 08b913918dd419fe48d01ef685781a69ced0a111
wpt-pr: 55938

Diffstat:
Mtesting/web-platform/tests/html/browsers/origin/tentative/api/origin-comparison.any.js | 11+++++++++++
1 file changed, 11 insertions(+), 0 deletions(-)

diff --git a/testing/web-platform/tests/html/browsers/origin/tentative/api/origin-comparison.any.js b/testing/web-platform/tests/html/browsers/origin/tentative/api/origin-comparison.any.js @@ -35,3 +35,14 @@ test(t => { assert_false(a_a.isSameSite(b), "Origins with different registrable domains should not be same-site."); assert_false(a_a.isSameSite(b_b), "Origins with different registrable domains should not be same-site."); }, "Comparison of tuple origins."); + +test(t => { + const http = new Origin("http://a.example"); + const https = new Origin("https://a.example"); + + assert_false(http.isSameOrigin(https), "http is not same-site with https"); + assert_false(https.isSameOrigin(http), "https is not same-site with http"); + + assert_false(http.isSameSite(https), "http is not same-site with https"); + assert_false(https.isSameSite(http), "https is not same-site with http"); +}, "Comparisons are schemeful.");