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

Add CI test no_std features #512

Closed
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 19 additions & 14 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ env:

jobs:
test:
name: Test All features
runs-on: ubuntu-latest
strategy:
matrix:
Expand All @@ -27,22 +28,13 @@ jobs:
- uses: dtolnay/rust-toolchain@stable
- run: rustup target add ${{ matrix.target }}
- run: ${{ matrix.deps }}
- run: cargo test --target ${{ matrix.target }} --no-default-features
- run: cargo test --target ${{ matrix.target }} --no-default-features --features alloc
- run: cargo test --target ${{ matrix.target }} --no-default-features --features digest
- run: cargo test --target ${{ matrix.target }} --no-default-features --features precomputed-tables
- run: cargo test --target ${{ matrix.target }} --no-default-features --features rand_core
- run: cargo test --target ${{ matrix.target }} --no-default-features --features serde
- run: cargo test --target ${{ matrix.target }} --no-default-features --features zeroize
- run: cargo test --target ${{ matrix.target }}
- run: cargo test --target ${{ matrix.target }} --features digest
- run: cargo test --target ${{ matrix.target }} --features rand_core
- run: cargo test --target ${{ matrix.target }} --features serde
- run: cargo test --target ${{ matrix.target }} --all-features
- env:
RUSTFLAGS: '--cfg curve25519_dalek_backend="fiat"'
run: cargo test --target ${{ matrix.target }}

build-nostd:
# Test no_std with no features
build-nostd-base:
name: Build on no_std target (thumbv7em-none-eabi)
runs-on: ubuntu-latest
steps:
Expand All @@ -51,9 +43,22 @@ jobs:
with:
toolchain: stable
targets: thumbv7em-none-eabi
- uses: taiki-e/install-action@cargo-hack
# No default features build
- run: cargo build --target thumbv7em-none-eabi --release --no-default-features
- run: cargo build --target thumbv7em-none-eabi --release
- run: cargo build --target thumbv7em-none-eabi --release --features serde

# Test no_std integration with all no_std features
build-nostd-features:
name: Build on no_std target (thumbv7em-none-eabi)
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: dtolnay/rust-toolchain@master
with:
toolchain: stable
targets: thumbv7em-none-eabi
- uses: taiki-e/install-action@cargo-hack
- run: cargo hack build --target thumbv7em-none-eabi --release --each-feature --exclude-features default,std

build-simd:
name: Build simd backend (nightly)
Expand Down