зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1648813: Verify acc description when waiting for load/layout event r=eeejay
Differential Revision: https://phabricator.services.mozilla.com/D105373
This commit is contained in:
Родитель
f7cda9a0be
Коммит
e71c1fa4ff
|
@ -35,8 +35,14 @@ addAccessibleTask(`<title>webarea test</title>`, async (browser, accDoc) => {
|
|||
// event for the document. Otherwise, if the iframe loads after the
|
||||
// document, we'll get one AXLoadComplete event.
|
||||
let eventPromise = Promise.race([
|
||||
waitForMacEvent("AXLayoutComplete"),
|
||||
waitForMacEvent("AXLoadComplete"),
|
||||
waitForMacEvent("AXLayoutComplete", (iface, data) => {
|
||||
return (
|
||||
iface.getAttributeValue("AXDescription") == "data:text/html,hello world"
|
||||
);
|
||||
}),
|
||||
waitForMacEvent("AXLoadComplete", (iface, data) => {
|
||||
return iface.getAttributeValue("AXDescription") == "webarea test";
|
||||
}),
|
||||
]);
|
||||
await SpecialPowers.spawn(browser, [], () => {
|
||||
const iframe = content.document.createElement("iframe");
|
||||
|
|
Загрузка…
Ссылка в новой задаче