-
Notifications
You must be signed in to change notification settings - Fork 1
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
Issue-105, Brro Compressor E2E Tests and test workflow imrpovement #117
Conversation
…gets before it fails
aa65a51
to
09acfa4
Compare
Tests fail here until #118 is fixed |
@@ -48,8 +48,28 @@ jobs: | |||
- name: Ensure that all crates compile and have no warnings under every possible combination of features | |||
# some things to explicitly point out: | |||
# * clippy also reports rustc warnings and errors | |||
# * clippy --all-targets causes clippy to run against tests and examples which it doesnt do by default. | |||
run: cargo hack --feature-powerset clippy --all-targets --locked ${{ matrix.cargo_flags }} -- -D warnings | |||
# * clippy --all-targets causes clippy to run against tests and examples which it doesn't do by default. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think we could achieve this more simply as:
run:
# Display all clippy lint failures as warnings
cargo hack --feature-powerset clippy --all-targets --locked ${{ matrix.cargo_flags }}
# Fail CI on the first crate to fail clippy lints
cargo hack --feature-powerset clippy --all-targets --locked ${{ matrix.cargo_flags }} -- -D warnings
Its the -D warnings
that causes clippy to abort and not continue on to other crates.
But we also need the -D warnings
to actually return non-zero exit code and fail CI.
Its also worth noting that clippy is easy to run locally, it is automatically installed already and you can just cargo clippy
to see most of the failures locally. (I think it skips tests and benches) Since we dont use any features in fft-compressor yet: cargo clippy --all-targets
will test everything including tests/benches
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks a lot! I like this approach much more. I added this one to the CI job.
Workflow improvement
The current workflow sequentially checks all crates in the workspace until one fails.
This PR solves this problem by running a script that runs
cargo clippy
on each project in the workspace separately. If one of those checks fails it stops the job when all checks are completed.Brro Compressor E2E
This PR covers the brro compressor CLI tool with a few e2e tests. It mostly covers compression and decompression flows.
Relates to #105