-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
Start migrating CI to Github Actions #2531
Conversation
c293cc8
to
9389154
Compare
First stepAs @carllerche suggested, I'm breaking this project up into stages. For now, I've recreated the tests specified in # Test top level crate
- template: ci/azure-test-stable.yml
parameters:
name: test_tokio
rust: stable
displayName: Test tokio
cross: true
crates:
- tokio
- tests-integration
# Test sub crates
- template: ci/azure-test-stable.yml
parameters:
name: test_linux
displayName: Test sub crates -
rust: stable
crates:
- tokio-macros
- tokio-test
- tokio-util
- examples DifferencesTechnically, it does slightly less work than the azure pipelines file since the "tokio - cargo test --features full" tests aren't run twice each on linux by the template inclusion in that second step. Let me know if that was desirable and not in fact redundant. There is a substantial difference in how the work is partitioned into jobs (I think). Because Github Actions doesn't have any analogs for the template inclusion or looping functionality in Azure Pipelines, I used the build matrix to run the same set of cargo invocations on the same platforms. So instead of four runners, there are 13. I also haven't yet included the functionality from Test ResultsTest results can be seen in my personal fork of Tokio |
What do you think about moving yaml file to shell script (like rust-lang/rust#65202)? (Personally, I think it may reduce the burden of migration (especially about the difference between syntax and supported features). In fact, the crossbeam's tests were written in shell script, which made the transition easier (but it's not as complicated a CI setting as tokio): https://github.com/crossbeam-rs/crossbeam/pull/489/files) |
Most of the same features are supported, and it was pretty simple to replace the usage of loop with using the job matrix. I think |
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've left a few nits about removing duplicate settings, this looks great overall!
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!
I merged this & I opened #2559 to track the migration of the remaining of the jobs. |
@RadicalZephyr thanks for getting this started and @taiki-e for following up 👍 |
This migrates test_tokio, test_sub_crates, and test_integration to GitHub Actions, as the first step in the migration from Azure Pipelines.
Templates aren't directly a feature in Github Actions, so I'm not going to attempt to parameterize the jobs the same way right now. Also, the
on:
conditions are so that the CI will fire on this PR while I'm developing it, the commented out version below is the correct final condition.