From f2e233d66a75e9308fda2f7b8a7c6662359fb50c Mon Sep 17 00:00:00 2001 From: Shunguo Date: Mon, 2 Dec 2024 22:14:37 -0600 Subject: [PATCH] Update achecker.cy.js --- .../test/cypress/e2e/achecker.cy.js | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/cypress-accessibility-checker/test/cypress/e2e/achecker.cy.js b/cypress-accessibility-checker/test/cypress/e2e/achecker.cy.js index e46085f4b..835735ded 100644 --- a/cypress-accessibility-checker/test/cypress/e2e/achecker.cy.js +++ b/cypress-accessibility-checker/test/cypress/e2e/achecker.cy.js @@ -44,7 +44,7 @@ context('Accessibility checker tests', () => { cy.visit('no-violations.html') .getCompliance('assert compliance rc 0 no baseline') .assertCompliance() - .then((rc) => {console.warn("no-violations rc=" + rc); + .then((rc) => { return expect(rc).to.equal(0) }); }); @@ -53,7 +53,7 @@ context('Accessibility checker tests', () => { cy.visit('violations.html') .getCompliance('violations') .assertCompliance(false) - .then((rc) => {console.warn("violations rc=" + rc); expect(rc).to.equal(0)}); + .then((rc) => expect(rc).to.equal(0)); }); it('Fails when the baselines dont match', () => { @@ -61,7 +61,7 @@ context('Accessibility checker tests', () => { cy.visit('violations.html') .getCompliance('violations-no-match') .assertCompliance(false) - .then((rc) => { console.warn("violations no match rc=" + rc); + .then((rc) => { expect(rc).to.equal(1); }) }); @@ -70,7 +70,7 @@ context('Accessibility checker tests', () => { cy.visit('violations.html') .getCompliance('assert compliance rc 2') .assertCompliance(false) // Don't actually run the assertion in the command so we can check the output - .then((rc) => {console.warn("violations rc2=" + rc);expect(rc).to.equal(2)}); + .then((rc) => expect(rc).to.equal(2)); }); });