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

dynamically discover smoke tests #8551

Merged
merged 5 commits into from
Dec 6, 2023

Conversation

jakecoffman
Copy link
Member

@jakecoffman jakecoffman commented Dec 6, 2023

When adding a new smoke test, we had to remember to also add it to this list of tests, which inevitably means we forgot.

This change pulls the list of tests from the smoke test so as long as it's on main it will be run!

It relies on convention that the "test" value in smoke-matrix.json matches the test name like so: smoke-$test-.yaml.

So I need to rename a few tests after merging this.

@jakecoffman jakecoffman marked this pull request as ready for review December 6, 2023 17:01
@jakecoffman jakecoffman requested a review from a team as a code owner December 6, 2023 17:01
@jakecoffman
Copy link
Member Author

Oh looks like there's a problem, the filter needs to be more strict: go_modules, gomod, smoke-cargo.yaml

@jakecoffman
Copy link
Member Author

It works!

The smoke test failures are expected due to a recent change in the PR body.

There's a few tests missing which will be fixed by dependabot/smoke-tests#153

@@ -43,8 +43,19 @@ jobs:
jq -c --argjson changes "$(cat changes.json)" '[.[] | select(.core as $p | $changes | index($p))]' .github/smoke-matrix.json > filtered.json
cat filtered.json

# Curl the smoke-test tests directory to get a list of tests to run
Copy link
Contributor

Choose a reason for hiding this comment

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

❤️

@jakecoffman jakecoffman merged commit a233247 into main Dec 6, 2023
120 checks passed
@jakecoffman jakecoffman deleted the jakecoffman/dynamically-discover-tests branch December 6, 2023 18:50
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.

2 participants