Skip to content

Commit 7aa370b

Browse files
Address comments
1 parent d4d602b commit 7aa370b

File tree

1 file changed

+14
-1
lines changed

1 file changed

+14
-1
lines changed

accessibility/scanner/index.js

Lines changed: 14 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ const setScanConfig = (win, payload) => {
4141
win.document.dispatchEvent(e);
4242

4343
setTimeout(() => {
44-
reject(new Error('automation-custom-event not received within timeout'));
44+
resolve(new Error('automation-custom-event not received within timeout'));
4545
}, 45000);
4646
});
4747
};
@@ -258,6 +258,19 @@ if (overRideCommands) {
258258
})
259259
})
260260

261+
afterEach(() => {
262+
console.log("after each hook")
263+
let isAccessibilityLoaded = Cypress.env("ACCESSIBILITY") || false;
264+
if (!isAccessibilityLoaded){
265+
console.log('log', "accessibility not enabled " + isAccessibilityLoaded);
266+
return;
267+
}
268+
cy.window().then((win) => {
269+
processAccessibilityReport(win);
270+
})
271+
272+
273+
})
261274
}
262275

263276

0 commit comments

Comments
 (0)