From d8bbc7858622b6d9c278469aab701ca0b609cddf Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Wed, 15 May 2024 05:35:49 +0200 Subject: Merging upstream version 126.0. Signed-off-by: Daniel Baumann --- .../shopping/tests/browser/browser_exposure_telemetry.js | 2 +- .../shopping/tests/browser/browser_shopping_settings.js | 8 ++++---- .../shopping/tests/browser/browser_shopping_urlbar.js | 10 +++++----- .../components/shopping/tests/browser/browser_ui_telemetry.js | 2 +- 4 files changed, 11 insertions(+), 11 deletions(-) (limited to 'browser/components/shopping/tests') diff --git a/browser/components/shopping/tests/browser/browser_exposure_telemetry.js b/browser/components/shopping/tests/browser/browser_exposure_telemetry.js index 51334ce722..f76126aa9d 100644 --- a/browser/components/shopping/tests/browser/browser_exposure_telemetry.js +++ b/browser/components/shopping/tests/browser/browser_exposure_telemetry.js @@ -30,7 +30,7 @@ async function setup(pref) { Services.fog.testResetFOG(); } -async function teardown(pref) { +async function teardown() { await SpecialPowers.popPrefEnv(); await Services.fog.testFlushAllChildren(); Services.fog.testResetFOG(); diff --git a/browser/components/shopping/tests/browser/browser_shopping_settings.js b/browser/components/shopping/tests/browser/browser_shopping_settings.js index 2508be05c7..a32488239e 100644 --- a/browser/components/shopping/tests/browser/browser_shopping_settings.js +++ b/browser/components/shopping/tests/browser/browser_shopping_settings.js @@ -16,7 +16,7 @@ add_task(async function test_shopping_settings_fakespot_learn_more() { await SpecialPowers.spawn( browser, [MOCK_ANALYZED_PRODUCT_RESPONSE], - async mockData => { + async () => { let shoppingContainer = content.document.querySelector( "shopping-container" @@ -55,7 +55,7 @@ add_task(async function test_shopping_settings_ads_learn_more() { await SpecialPowers.spawn( browser, [MOCK_ANALYZED_PRODUCT_RESPONSE], - async mockData => { + async () => { let shoppingContainer = content.document.querySelector( "shopping-container" @@ -404,7 +404,7 @@ add_task( await SpecialPowers.spawn( sidebar.querySelector("browser"), [MOCK_ANALYZED_PRODUCT_RESPONSE], - async mockData => { + async () => { let shoppingContainer = content.document.querySelector( "shopping-container" @@ -490,7 +490,7 @@ add_task( await SpecialPowers.spawn( sidebar.querySelector("browser"), [MOCK_ANALYZED_PRODUCT_RESPONSE], - async mockData => { + async () => { let shoppingContainer = content.document.querySelector( "shopping-container" diff --git a/browser/components/shopping/tests/browser/browser_shopping_urlbar.js b/browser/components/shopping/tests/browser/browser_shopping_urlbar.js index 9eb396e846..d89db3ebcb 100644 --- a/browser/components/shopping/tests/browser/browser_shopping_urlbar.js +++ b/browser/components/shopping/tests/browser/browser_shopping_urlbar.js @@ -7,7 +7,7 @@ const CONTENT_PAGE = "https://example.com"; const PRODUCT_PAGE = "https://example.com/product/B09TJGHL5F"; add_task(async function test_button_hidden() { - await BrowserTestUtils.withNewTab(CONTENT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(CONTENT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); ok( BrowserTestUtils.isHidden(shoppingButton), @@ -17,7 +17,7 @@ add_task(async function test_button_hidden() { }); add_task(async function test_button_shown() { - await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); ok( BrowserTestUtils.isVisible(shoppingButton), @@ -52,7 +52,7 @@ add_task(async function test_button_changes_with_location() { add_task(async function test_button_active() { Services.prefs.setBoolPref("browser.shopping.experience2023.active", true); - await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); Assert.equal( shoppingButton.getAttribute("shoppingsidebaropen"), @@ -65,7 +65,7 @@ add_task(async function test_button_active() { add_task(async function test_button_inactive() { Services.prefs.setBoolPref("browser.shopping.experience2023.active", false); - await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); Assert.equal( shoppingButton.getAttribute("shoppingsidebaropen"), @@ -245,7 +245,7 @@ add_task(async function test_button_right_click_doesnt_affect_sidebars() { add_task(async function test_button_deals_with_tabswitches() { Services.prefs.setBoolPref("browser.shopping.experience2023.active", true); - await BrowserTestUtils.withNewTab(CONTENT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(CONTENT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); ok( diff --git a/browser/components/shopping/tests/browser/browser_ui_telemetry.js b/browser/components/shopping/tests/browser/browser_ui_telemetry.js index b97aca1963..69bdf50bd1 100644 --- a/browser/components/shopping/tests/browser/browser_ui_telemetry.js +++ b/browser/components/shopping/tests/browser/browser_ui_telemetry.js @@ -259,7 +259,7 @@ add_task(async function test_close_telemetry_recorded() { set: [["browser.shopping.experience2023.active", true]], }); - await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function (browser) { + await BrowserTestUtils.withNewTab(PRODUCT_PAGE, async function () { let shoppingButton = document.getElementById("shopping-sidebar-button"); shoppingButton.click(); }); -- cgit v1.2.3