diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-15 03:35:49 +0000 |
commit | d8bbc7858622b6d9c278469aab701ca0b609cddf (patch) | |
tree | eff41dc61d9f714852212739e6b3738b82a2af87 /toolkit/components/printing/tests | |
parent | Releasing progress-linux version 125.0.3-1~progress7.99u1. (diff) | |
download | firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.tar.xz firefox-d8bbc7858622b6d9c278469aab701ca0b609cddf.zip |
Merging upstream version 126.0.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'toolkit/components/printing/tests')
3 files changed, 9 insertions, 7 deletions
diff --git a/toolkit/components/printing/tests/browser_preview_navigation.js b/toolkit/components/printing/tests/browser_preview_navigation.js index 53e54eddb0..23b3a9b7cc 100644 --- a/toolkit/components/printing/tests/browser_preview_navigation.js +++ b/toolkit/components/printing/tests/browser_preview_navigation.js @@ -23,7 +23,7 @@ async function waitForPageStatusUpdate(elem, expected, message) { ); } -async function waitUntilVisible(elem, visible = true) { +async function waitUntilVisible(elem) { await TestUtils.waitForCondition( () => BrowserTestUtils.isVisible(elem) && getComputedStyle(elem).opacity == "1", diff --git a/toolkit/components/printing/tests/file_window_print_reentrant.html b/toolkit/components/printing/tests/file_window_print_reentrant.html index 7eebd8c2fe..2008ffaf27 100644 --- a/toolkit/components/printing/tests/file_window_print_reentrant.html +++ b/toolkit/components/printing/tests/file_window_print_reentrant.html @@ -3,7 +3,7 @@ <script> let count = 0; onload = function() { - window.addEventListener('beforeprint', (event) => { + window.addEventListener('beforeprint', () => { document.getElementById("before-print-count").innerText = ++count; print() }); diff --git a/toolkit/components/printing/tests/head.js b/toolkit/components/printing/tests/head.js index 4c8c0b26b6..e2a83463a6 100644 --- a/toolkit/components/printing/tests/head.js +++ b/toolkit/components/printing/tests/head.js @@ -60,6 +60,9 @@ class PrintHelper { } static getTestPageUrl(pathName) { + if (pathName.startsWith("http://")) { + return pathName; + } const testPath = getRootDirectory(gTestPath).replace( "chrome://mochitests/content", "http://example.com" @@ -68,6 +71,9 @@ class PrintHelper { } static getTestPageUrlHTTPS(pathName) { + if (pathName.startsWith("https://")) { + return pathName; + } const testPath = getRootDirectory(gTestPath).replace( "chrome://mochitests/content", "https://example.com" @@ -232,11 +238,7 @@ class PrintHelper { }); // Mock PrintEventHandler with our Promises. - this.win.PrintEventHandler._showPrintDialog = ( - window, - haveSelection, - settings - ) => { + this.win.PrintEventHandler._showPrintDialog = (window, haveSelection) => { this.systemDialogOpenedWithSelection = haveSelection; return showSystemDialogPromise; }; |