mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-27 14:52:16 +00:00
Bug 1499474 - Check if the element has textContent before falling back to TestUtils.waitForCondition. r=MattN
This patch reduced the time to run from 2 minutes to 15 seconds. Differential Revision: https://phabricator.services.mozilla.com/D8895 --HG-- extra : moz-landing-system : lando
This commit is contained in:
parent
a5fabb8cb9
commit
d95c5b459f
@ -324,8 +324,11 @@ add_task(async function test_countryFieldLabels() {
|
||||
|
||||
// Check that the labels were filled
|
||||
for (let labelEl of mutatableLabels) {
|
||||
await TestUtils.waitForCondition(() => labelEl.textContent,
|
||||
"Wait for label to be populated by the mutation observer");
|
||||
if (!labelEl.textContent) {
|
||||
await TestUtils.waitForCondition(() => labelEl.textContent,
|
||||
"Wait for label to be populated by the mutation observer",
|
||||
10);
|
||||
}
|
||||
isnot(labelEl.textContent, "",
|
||||
"Ensure textContent is non-empty for: " + countryOption.value);
|
||||
is(labelEl.dataset.localization, undefined,
|
||||
|
Loading…
Reference in New Issue
Block a user