Add logging for violations & testA11y() in utils.ts. Use that method everywhere else

This commit is contained in:
Tim Donohue
2021-09-13 17:11:53 -05:00
parent fad74a4ca2
commit 4faa850fba
16 changed files with 100 additions and 65 deletions

View File

@@ -1,3 +1,5 @@
import { testA11y } from 'cypress/support/utils';
describe('Homepage', () => {
beforeEach(() => {
// All tests start with visiting homepage
@@ -21,12 +23,10 @@ describe('Homepage', () => {
});
it('should pass accessibility tests', () => {
cy.injectAxe();
// Wait for homepage tag to appear
cy.get('ds-home-page').should('be.visible');
// Analyze <ds-home-page> for accessibility issues
cy.checkA11y('ds-home-page');
testA11y('ds-home-page');
});
});