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

Simplify GH Actions config with matrix syntax #8253

Merged
merged 4 commits into from
Oct 18, 2021
Merged

Simplify GH Actions config with matrix syntax #8253

merged 4 commits into from
Oct 18, 2021

Conversation

mkllnk
Copy link
Member

@mkllnk mkllnk commented Sep 28, 2021

What? Why?

Our config is very repetitive. Let's try to DRY it so that it's easier to maintain.

Initially, I wanted to use Knapsack which does a much better job at balancing. But system specs have to run separately at the moment and there's no easy way to exclude spec files from loading when using Knapsack (you can exclude them from execution, but not loading). So I kept the current directory lists.

What should we test?

Specs have to pass.

Release notes

Changelog Category: Technical changes

Simplified config for Github Actions.

@mkllnk mkllnk self-assigned this Sep 28, 2021
Copy link
Contributor

@andrewpbrett andrewpbrett left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🎉 🙏

@mkllnk mkllnk requested a review from Matt-Yorkley October 8, 2021 05:45
This demonstrates how you can split the tests across multiple jobs
without repeating the job configuration. This has a lot of potential to
DRY our config.
This uses the matrix syntax for all rspec calls. It is easier to
maintain than the previous list of GH Actions workflows.

The execution of the rspec rake task is still in its own job because it
doesn't fit in the same pattern. The JS tests are also executed in that
job.
It's already defined globally.
It's nice to see the whole result to then work on all failures,
especially when there are flaky specs.
@mkllnk
Copy link
Member Author

mkllnk commented Oct 18, 2021

Thank you, just rebasing to make sure all tests are still good.

@mkllnk mkllnk merged commit 0ffe73c into openfoodfoundation:master Oct 18, 2021
@mkllnk mkllnk deleted the spec-matrix branch October 18, 2021 22:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants