Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

ci: test AArch64 Linux and run tests instead of build in cross job #763

Merged
merged 1 commit into from
Jan 27, 2025

Conversation

taiki-e
Copy link
Member

@taiki-e taiki-e commented Jan 25, 2025

Motivation

Currently, "cross" job in our CI is build-only and doesn't run tests:

- name: cross build --target ${{ matrix.target }}
run: cross build --target ${{ matrix.target }}
if: matrix.target != 'wasm32-unknown-unknown'
# WASM support
- name: cargo build --target ${{ matrix.target }}
run: |
rustup target add ${{ matrix.target }}
cargo build --target ${{ matrix.target }}
if: matrix.target == 'wasm32-unknown-unknown'

And AArch64 Linux which is tier1 in rustc is not tested.

matrix:
target:
- i686-unknown-linux-gnu
- armv7-unknown-linux-gnueabihf
- powerpc-unknown-linux-gnu
- powerpc64-unknown-linux-gnu
- wasm32-unknown-unknown
runs-on: ubuntu-latest

Solution

This PR adds aarc64-unknown-linux-gnu (ubuntu-22.04-arm) to matrix of tests on stable ("stable" job), and update "cross" job to run tests by using setup-cross-toolchain-action which is used in tokio. (see also tokio-rs/tokio#7123 for AArch64/Armv7hf)

As for WASM testing, use wasm32-wasip1 instead of wasm32-unknown-unknown because wasm32-wasip1 can test with cargo test command. (Testing wasm32-unknown-unknown usually needs wasm-pack or other commands.)

@taiki-e taiki-e changed the title ci: test AArch64 and run tests instead of build in cross job ci: test AArch64 Linux and run tests instead of build in cross job Jan 25, 2025
Copy link
Contributor

@Darksonn Darksonn left a comment

Choose a reason for hiding this comment

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

Thanks.

@Darksonn Darksonn merged commit 71824b0 into master Jan 27, 2025
17 checks passed
@Darksonn Darksonn deleted the taiki-e/cross-test branch January 27, 2025 09:58
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants