Bug 1630320 - in browser_autocomplete_footer.js wait for the tab to load before attempting to retrieve its content. r=Gijs

Differential Revision: https://phabricator.services.mozilla.com/D72507
This commit is contained in:
Jean-Yves Avenard 2020-04-25 14:50:22 +00:00
Родитель 5e943e0b75
Коммит 4a3efc9476
1 изменённых файлов: 4 добавлений и 2 удалений

Просмотреть файл

@ -25,7 +25,8 @@ add_task(async function test_press_enter_on_footer() {
); );
const prefTabPromise = BrowserTestUtils.waitForNewTab( const prefTabPromise = BrowserTestUtils.waitForNewTab(
gBrowser, gBrowser,
PRIVACY_PREF_URL PRIVACY_PREF_URL,
true
); );
for (let i = 0; i < listItemElems.length; i++) { for (let i = 0; i < listItemElems.length; i++) {
await BrowserTestUtils.synthesizeKey("VK_DOWN", {}, browser); await BrowserTestUtils.synthesizeKey("VK_DOWN", {}, browser);
@ -59,7 +60,8 @@ add_task(async function test_click_on_footer() {
)._optionButton; )._optionButton;
const prefTabPromise = BrowserTestUtils.waitForNewTab( const prefTabPromise = BrowserTestUtils.waitForNewTab(
gBrowser, gBrowser,
PRIVACY_PREF_URL PRIVACY_PREF_URL,
true
); );
// Wait for dropdown animation finished to continue mouse synthesizing. // Wait for dropdown animation finished to continue mouse synthesizing.
await sleep(3000); await sleep(3000);