mirror of
https://github.com/mozilla/gecko-dev.git
synced 2025-02-24 11:27:49 +00:00
Bug 1764690 - [devtools] Check data-l10n-args attribute value instead of context menu label in storage tests. r=bomsy.
These tests are failing intermittently as, I think, the label gets localized asynchronously. So instead of checking the computed translated string, we only check that the attribute for the item name is properly set. Differential Revision: https://phabricator.services.mozilla.com/D144163
This commit is contained in:
parent
7353e17494
commit
1ac5da6a36
@ -63,7 +63,9 @@ add_task(async function() {
|
||||
.replace(SEPARATOR_GUID, "-")
|
||||
.substr(0, 16);
|
||||
ok(
|
||||
menuDeleteItem.getAttribute("label").includes(truncatedRowName),
|
||||
JSON.parse(
|
||||
menuDeleteItem.getAttribute("data-l10n-args")
|
||||
).itemName.includes(truncatedRowName),
|
||||
`Context menu item label contains '${rowName}' (maybe truncated)`
|
||||
);
|
||||
});
|
||||
|
@ -216,7 +216,9 @@ add_task(async function() {
|
||||
.replace(SEPARATOR_GUID, "-")
|
||||
.substr(0, 16);
|
||||
ok(
|
||||
menuDeleteItem.getAttribute("label").includes(truncatedRowName),
|
||||
JSON.parse(
|
||||
menuDeleteItem.getAttribute("data-l10n-args")
|
||||
).itemName.includes(truncatedRowName),
|
||||
`Context menu item label contains '${rowName}' (maybe truncated)`
|
||||
);
|
||||
});
|
||||
|
Loading…
x
Reference in New Issue
Block a user