tor-browser

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

commit 21c17d41b87bad7091b83bbbe6122033a8238353
parent 57ce1d0e0ec9681fdfc24ccb370833f468a2aecd
Author: Thomas Wisniewski <twisniewski@mozilla.com>
Date:   Tue,  2 Dec 2025 18:41:13 +0000

Bug 1898916 - add a desktop-only UA override for www.smartmirror.link; r=ksenia,webcompat-reviewers

Differential Revision: https://phabricator.services.mozilla.com/D274655

Diffstat:
Mbrowser/extensions/webcompat/data/interventions.json | 15+++++++++++++++
Atesting/webcompat/interventions/tests/test_1898916_smartmirror_link.py | 23+++++++++++++++++++++++
2 files changed, 38 insertions(+), 0 deletions(-)

diff --git a/browser/extensions/webcompat/data/interventions.json b/browser/extensions/webcompat/data/interventions.json @@ -2071,6 +2071,21 @@ } ] }, + "1898916": { + "label": "smartmirror.link", + "bugs": { + "1898916": { + "issue": "firefox-blocked-completely", + "matches": ["*://www.smartmirror.link/*"] + } + }, + "interventions": [ + { + "platforms": ["desktop"], + "ua_string": ["add_Chrome"] + } + ] + }, "1898936": { "label": "app.stormx.io", "bugs": { diff --git a/testing/webcompat/interventions/tests/test_1898916_smartmirror_link.py b/testing/webcompat/interventions/tests/test_1898916_smartmirror_link.py @@ -0,0 +1,23 @@ +import pytest + +URL = "https://www.smartmirror.link/" +SUPPORTED_CSS = "[class*=join][class*=connect]" +UNSUPPORTED_CSS = "[class*=unsupported-browser]" + + +@pytest.mark.skip_platforms("android") +@pytest.mark.asyncio +@pytest.mark.with_interventions +async def test_enabled(client): + await client.navigate(URL, wait="none") + assert client.await_css(SUPPORTED_CSS, is_displayed=True) + assert not client.find_css(UNSUPPORTED_CSS, is_displayed=True) + + +@pytest.mark.skip_platforms("android") +@pytest.mark.asyncio +@pytest.mark.without_interventions +async def test_disabled(client): + await client.navigate(URL, wait="none") + assert client.await_css(UNSUPPORTED_CSS, is_displayed=True) + assert not client.find_css(SUPPORTED_CSS, is_displayed=True)