Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

skipAudits flag is not processed correctly by lighthouse #612

Open
BioPhoton opened this issue Apr 9, 2024 · 0 comments
Open

skipAudits flag is not processed correctly by lighthouse #612

BioPhoton opened this issue Apr 9, 2024 · 0 comments
Labels
🐛 bug something isn't working 🧩 lighthouse-plugin

Comments

@BioPhoton
Copy link
Collaborator

What happened?

When I configure a audit slug for skipAudits in the plugin options the audit is filtered out from the plugin config audits but the listed audits still show up in the audit outputs of the plugin. Therefor we had to implement the normalizeAuditOutputs function to overcome the validation.

What would you expect to happen?

That runLighthouse processes the passed flags correctly

What steps did you take?

Ensure original logic:

  1. ✅ run npx lighthouse https://example.com --skipAudits is-on-https --output json --output-path report.json
  2. ✅ ensure audits do NOT contain is-on-https
  3. ✅ ensure configSetings.skipAudits is set to ["is-on-https"]

Ensure cp logic:

  1. ✅ run nx code-pushup -- --onlyPlugins lighthouse with the following plugin configuration
 await lighthousePlugin('https://codepushup.dev/', { skipAudits: ['is-on-https'] })
  1. ✅ ensure skipAudits is passed into runLighthouse
  2. ❌ ensure audits do NOT contain is-on-https => the audit is present
  3. ✅ ensure configSetings.skipAudits is set to ["is-on-https"]

Related source links:

Code PushUp package version

No response

What operation system are you on?

MacOS

Node version

No response

Relevant log output

No response

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 bug something isn't working 🧩 lighthouse-plugin
Projects
None yet
Development

No branches or pull requests

1 participant