Skip to content

Conversation

@BioPhoton
Copy link
Collaborator

@BioPhoton BioPhoton commented Mar 8, 2024

This PR wraps lighthouse core functionality exported as ESM with a PluginRunner for the @code-pushup/lighthouse-plugin package.

It aims to leverage all functionality directly over reusing their ESM exports instead of using the CLI.
This is less code to maintain as well as faster to execute and more scalable in terms of process arguments.

Changes included in this PR:

  • plugin options mirroring runLighthouse, the core functionality of lighthouse. The following arguments are defined: url, flags and config.
  • a getRunner is implemented to get a lighthouse runner receiving the url, flags and config arguments
    • Parts of the functionality of lighthouse CLI are excluded: all commands that don't produce a report, latern data logic.
      The user is informed about missing implementations if by accident provided over the CLI flags or config object
  • additional helper to generate and validate the used flags and config object
  • added CONTRIBUTING.md to document setup and debugging of Lighthouse
  • setup CI for Lighthouse path configuration on windows

Follow up PR:

Note

There is one thing left, I want to have the env variable only set for Windows in the CI.

References:

related to #90

@BioPhoton BioPhoton changed the title Add lighthouse runner feat(plugin-lighthouse): add lighthouse runner Mar 8, 2024
# Conflicts:
#	packages/plugin-lighthouse/src/lib/utils.unit.test.ts
@github-actions github-actions bot added the 📖 Project documentation improvements or additions to the project documentation label Mar 8, 2024
@BioPhoton BioPhoton self-assigned this Mar 8, 2024
@github-actions github-actions bot added the 🦾 CI/CD Continuous integration and deployment label Mar 9, 2024
matejchalk
matejchalk previously approved these changes Apr 2, 2024
…on.test.ts

Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
BioPhoton and others added 6 commits April 2, 2024 12:38
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
@BioPhoton BioPhoton requested a review from Tlacenka April 2, 2024 10:47
BioPhoton and others added 2 commits April 2, 2024 17:59
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Co-authored-by: Katka Pilátová <katerina.pilatova@flowup.cz>
Tlacenka
Tlacenka previously approved these changes Apr 2, 2024
Tlacenka
Tlacenka previously approved these changes Apr 2, 2024
@BioPhoton BioPhoton merged commit 9098d49 into main Apr 3, 2024
@BioPhoton BioPhoton deleted the add-lighthouse-runner branch April 3, 2024 12:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🦾 CI/CD Continuous integration and deployment 🧩 lighthouse-plugin 📖 Project documentation improvements or additions to the project documentation 🔬 testing writing tests 🛠️ tooling 🧩 utils

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants