From b490d71825ed1d6cefbe9f6a098f70a5b80d5669 Mon Sep 17 00:00:00 2001 From: MohamedRaslan <38933052+MohamedRaslan@users.noreply.github.com> Date: Thu, 26 May 2022 20:21:35 +0200 Subject: [PATCH] fix the tests --- cypress/plugins/index.js | 11 ++++++----- 1 file changed, 6 insertions(+), 5 deletions(-) diff --git a/cypress/plugins/index.js b/cypress/plugins/index.js index 376d192..e7ae20e 100644 --- a/cypress/plugins/index.js +++ b/cypress/plugins/index.js @@ -21,18 +21,19 @@ const injectCodeCoverage = require('@cypress/code-coverage/task'); // eslint-disable-next-line no-unused-vars -const { lighthouse, prepareAudit } = require('@cypress-audit/lighthouse'); -const { pa11y } = require('@cypress-audit/pa11y'); +const lighthouseConfig = require('@cypress-audit/lighthouse'); +const pa11yConfig = require('@cypress-audit/pa11y'); module.exports = (on, config) => { // eslint-disable-next-line no-unused-vars on('before:browser:launch', (browser = {}, launchOptions) => { - prepareAudit(launchOptions); + lighthouseConfig.prepareAudit(launchOptions); + pa11yConfig.prepareAudit(launchOptions); }); on('task', { - lighthouse: lighthouse(), - pa11y: pa11y((pa11yReport) => { + lighthouse: lighthouseConfig.lighthouse(), + pa11y: pa11yConfig.pa11y((pa11yReport) => { console.log(pa11yReport); // raw pa11y reports }), });