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

sha3: Add cross tests #339

Merged
merged 1 commit into from Dec 19, 2021
Merged

sha3: Add cross tests #339

merged 1 commit into from Dec 19, 2021

Conversation

aewag
Copy link
Contributor

@aewag aewag commented Dec 16, 2021

Well, that escalated quickly... Sorry for any noise!

This PR adds cross-tests to sha3 crate. It does so by using the composite action named cross-tests, which can be found in .github/actions/cross-tests/action.yml

Inputs to the cross-tests actions are: Rust Version, Package, Target & Features

I adapted the sha1 & sha2 crate to use the same composite action to reduce duplicated code (other crates seemed not to use any cross-tests).

Further I changed the place where MSRV is defined. It now can be set in the env section in the beginning of the .yml file at a single place.
Disadvantage: It needs one job run before anything else to distribute it. But that could also be used in the future to create the Strategy Matrix at a single place and distribute it to the jobs.

Issue came up in #338

@aewag aewag force-pushed the add-cross-tests branch 13 times, most recently from bdf4ee4 to 3738f08 Compare December 16, 2021 17:01
@aewag aewag changed the title WIP sha3: Add cross tests WIP Add cross tests Dec 16, 2021
@aewag aewag force-pushed the add-cross-tests branch 16 times, most recently from 0c5fc3e to a977119 Compare December 16, 2021 18:08
@aewag aewag force-pushed the add-cross-tests branch 20 times, most recently from c266f91 to 978ef7b Compare December 17, 2021 10:49
@aewag aewag marked this pull request as ready for review December 17, 2021 11:09
@aewag aewag changed the title WIP Add cross tests Add cross tests Dec 17, 2021
@aewag aewag changed the title Add cross tests sha3: Add cross tests Dec 17, 2021
Copy link
Member

@tarcieri tarcieri left a comment

Choose a reason for hiding this comment

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

Interesting. TIL composite actions.

Looks good to me, but I'll let @newpavlov review as well.

@tarcieri
Copy link
Member

Going to merge this. It seems good for cross-checking crates, and with the composite action maybe we can wire up additional checks for other crates (e.g. blake2)

@tarcieri tarcieri merged commit e479909 into RustCrypto:master Dec 19, 2021
@aewag
Copy link
Contributor Author

aewag commented Dec 19, 2021

Thanks. :)
I don't know, if other RustCrypto crates could benefit from cross-tests or are already running some, but if so it could make sense to keep generic composite actions, such as cross, stored in a single repo.

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.

None yet

2 participants