mirror of
https://github.com/signalapp/libsignal.git
synced 2024-09-20 03:52:17 +02:00
CI: Run everyday tests with pinned Rust version, not latest stable
...in addition to our usual nightly. Move the run commands for latest-stable to the Slow Tests (reusing the cross-protocol-version testing job rather than making a new one).
This commit is contained in:
parent
3e8acec1a6
commit
48eb4c0f3c
37
.github/workflows/build_and_test.yml
vendored
37
.github/workflows/build_and_test.yml
vendored
@ -9,6 +9,7 @@ env:
|
||||
CARGO_TERM_COLOR: always
|
||||
NDK_VERSION: 25.2.9519653
|
||||
RUST_BACKTRACE: 1
|
||||
LIBSIGNAL_MINIMUM_SUPPORTED_RUST_VERSION: 1.72
|
||||
|
||||
jobs:
|
||||
changes:
|
||||
@ -98,16 +99,17 @@ jobs:
|
||||
matrix:
|
||||
version: [nightly, stable]
|
||||
include:
|
||||
- version: stable
|
||||
toolchain: "+stable"
|
||||
- version: nightly
|
||||
toolchain: "$(cat rust-toolchain)"
|
||||
- version: stable
|
||||
toolchain: "${LIBSIGNAL_MINIMUM_SUPPORTED_RUST_VERSION}"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- run: sudo apt-get update && sudo apt-get install protobuf-compiler
|
||||
|
||||
- run: rustup toolchain install $(cat rust-toolchain) --profile minimal --component rustfmt,clippy
|
||||
if: matrix.version == 'nightly'
|
||||
- run: rustup toolchain install ${{ matrix.toolchain }} --profile minimal --component rustfmt,clippy
|
||||
|
||||
- name: Cache locally-built tools
|
||||
uses: actions/cache@v3
|
||||
@ -143,16 +145,16 @@ jobs:
|
||||
if: matrix.version == 'nightly'
|
||||
|
||||
- name: Build
|
||||
run: cargo ${{ matrix.toolchain }} build --workspace --features libsignal-ffi/signal-media --verbose
|
||||
run: cargo +${{ matrix.toolchain }} build --workspace --features libsignal-ffi/signal-media --verbose
|
||||
|
||||
- name: Run tests
|
||||
run: cargo ${{ matrix.toolchain }} test --workspace --all-features --verbose -- --include-ignored
|
||||
run: cargo +${{ matrix.toolchain }} test --workspace --all-features --verbose -- --include-ignored
|
||||
|
||||
- name: Test run benches
|
||||
run: cargo ${{ matrix.toolchain }} test --workspace --benches --all-features --verbose
|
||||
run: cargo +${{ matrix.toolchain }} test --workspace --benches --all-features --verbose
|
||||
|
||||
- name: Build bins and examples
|
||||
run: cargo ${{ matrix.toolchain }} build --workspace --bins --examples --all-features --verbose
|
||||
run: cargo +${{ matrix.toolchain }} build --workspace --bins --examples --all-features --verbose
|
||||
|
||||
- name: Clippy
|
||||
run: cargo clippy --workspace --all-targets --all-features -- -D warnings
|
||||
@ -168,14 +170,14 @@ jobs:
|
||||
# See https://github.com/dtolnay/proc-macro2/issues/307 for an example.
|
||||
|
||||
- name: Check that the protocol fuzz target still builds
|
||||
run: cargo +stable check --all-targets
|
||||
run: cargo +${{ matrix.toolchain }} check --all-targets
|
||||
working-directory: rust/protocol/fuzz
|
||||
env:
|
||||
RUSTFLAGS: --cfg fuzzing
|
||||
if: matrix.version == 'stable'
|
||||
|
||||
- name: Check that the attest fuzz target still builds
|
||||
run: cargo +stable check --all-targets
|
||||
run: cargo +${{ matrix.toolchain }} check --all-targets
|
||||
working-directory: rust/attest/fuzz
|
||||
env:
|
||||
RUSTFLAGS: --cfg fuzzing
|
||||
@ -195,24 +197,21 @@ jobs:
|
||||
matrix:
|
||||
version: [nightly, stable]
|
||||
include:
|
||||
- version: stable
|
||||
toolchain: "+stable"
|
||||
- version: nightly
|
||||
toolchain: "$(cat rust-toolchain)"
|
||||
- version: stable
|
||||
toolchain: "${LIBSIGNAL_MINIMUM_SUPPORTED_RUST_VERSION}"
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- run: sudo apt-get update && sudo apt-get install gcc-multilib g++-multilib protobuf-compiler
|
||||
|
||||
- run: rustup toolchain install $(cat rust-toolchain) --profile minimal --target i686-unknown-linux-gnu
|
||||
if: matrix.version == 'nightly'
|
||||
|
||||
- name: Install Rust (stable)
|
||||
run: rustup +stable target add i686-unknown-linux-gnu
|
||||
if: matrix.version == 'stable'
|
||||
- run: rustup toolchain install ${{ matrix.toolchain }} --profile minimal --target i686-unknown-linux-gnu
|
||||
|
||||
- name: Run tests (32-bit)
|
||||
# Exclude signal-neon-futures because those tests run Node
|
||||
run: cargo ${{ matrix.toolchain }} test --workspace --all-features --verbose --target i686-unknown-linux-gnu --exclude signal-neon-futures -- --include-ignored
|
||||
run: cargo +${{ matrix.toolchain }} test --workspace --all-features --verbose --target i686-unknown-linux-gnu --exclude signal-neon-futures -- --include-ignored
|
||||
|
||||
java:
|
||||
name: Java
|
||||
|
21
.github/workflows/slow_tests.yml
vendored
21
.github/workflows/slow_tests.yml
vendored
@ -178,8 +178,8 @@ jobs:
|
||||
# No import validation because it tries to build unsupported platforms (like 32-bit iOS).
|
||||
run: pod lib lint --verbose --platforms=ios --include-podspecs=SignalCoreKit/SignalCoreKit.podspec --skip-import-validation
|
||||
|
||||
rust-protocol-cross-version-testing:
|
||||
name: libsignal-protocol Cross-version Tests
|
||||
rust-stable-testing:
|
||||
name: Rust tests (using latest stable)
|
||||
runs-on: ubuntu-latest
|
||||
needs: [check-up-to-date]
|
||||
if: ${{ always() && (needs.check-up-to-date.outputs.has-changes || github.event_name != 'schedule') }}
|
||||
@ -192,10 +192,23 @@ jobs:
|
||||
- run: rustup +stable target add i686-unknown-linux-gnu
|
||||
|
||||
- name: Run tests
|
||||
run: cargo +stable test --workspace --all-features --verbose -- --include-ignored
|
||||
|
||||
- name: Test run benches
|
||||
run: cargo +stable test --workspace --benches --all-features --verbose
|
||||
|
||||
- name: Build bins and examples
|
||||
run: cargo +stable build --workspace --bins --examples --all-features --verbose
|
||||
|
||||
- name: Run tests (32-bit)
|
||||
# Exclude signal-neon-futures because those tests run Node
|
||||
run: cargo +stable test --workspace --all-features --verbose --target i686-unknown-linux-gnu --exclude signal-neon-futures -- --include-ignored
|
||||
|
||||
- name: Run libsignal-protocol cross-version tests
|
||||
run: cargo +stable test
|
||||
working-directory: rust/protocol/cross-version-testing
|
||||
|
||||
- name: Run tests (32-bit)
|
||||
- name: Run libsignal-protocol cross-version tests (32-bit)
|
||||
run: cargo +stable test --target i686-unknown-linux-gnu
|
||||
working-directory: rust/protocol/cross-version-testing
|
||||
|
||||
@ -205,7 +218,7 @@ jobs:
|
||||
report_failures:
|
||||
name: Report Failures
|
||||
runs-on: ubuntu-latest
|
||||
needs: [java-docker, android-emulator-tests, node-docker, node-windows-arm64, swift-cocoapod, rust-protocol-cross-version-testing]
|
||||
needs: [java-docker, android-emulator-tests, node-docker, node-windows-arm64, swift-cocoapod, rust-stable-testing]
|
||||
if: ${{ failure() && github.event_name == 'schedule' }}
|
||||
|
||||
permissions:
|
||||
|
Loading…
Reference in New Issue
Block a user