mirror of
https://github.com/NoRedInk/noredink-ui.git
synced 2024-11-13 07:48:26 +03:00
click measure and render before running axe
This commit is contained in:
parent
3f4fa44ed9
commit
a304446144
@ -85,6 +85,20 @@ describe("UI tests", function () {
|
||||
await callback(option);
|
||||
};
|
||||
|
||||
const questionBoxProcessing = async (name, location) => {
|
||||
await goTo(name, location);
|
||||
|
||||
const [button] = await page.$x("//button[contains(., 'Measure & render')]");
|
||||
await button.click();
|
||||
|
||||
await percySnapshot(page, name);
|
||||
|
||||
const results = await new AxePuppeteer(page)
|
||||
.disableRules(skippedRules[name] || [])
|
||||
.analyze();
|
||||
handleAxeResults(name, results);
|
||||
};
|
||||
|
||||
const messageProcessing = async (name, location) => {
|
||||
await goTo(name, location);
|
||||
await percySnapshot(page, name);
|
||||
@ -160,6 +174,7 @@ describe("UI tests", function () {
|
||||
};
|
||||
|
||||
const specialProcessing = {
|
||||
QuestionBox: questionBoxProcessing,
|
||||
Message: messageProcessing,
|
||||
Modal: modalProcessing,
|
||||
Page: pageProcessing,
|
||||
|
Loading…
Reference in New Issue
Block a user