on: [push, pull_request]
env:
RUST_BACKTRACE: full
RUST_LOG: debug
CARGO_PROFILE_TEST_BUILD_OVERRIDE_DEBUG: true
name: Test
jobs:
test:
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
name: Test Suite
runs-on: ${{ matrix.os }}
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Run cargo test
uses: actions-rs/cargo@v1
with:
command: test
args: --features nalgebra,parallelism,async,mzsignal,thermo,numpress,bruker_tdf -- --nocapture --show-output
test-remote:
name: PROXI Test Suite
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Run cargo test
continue-on-error: true
uses: actions-rs/cargo@v1
with:
command: test
args: --features async,proxi,proxi-async -- --nocapture --show-output
test-pymzdata:
name: pymzdata Python Test Suite
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: "3.10"
- name: Build pymzdata wheel
uses: PyO3/maturin-action@v1
with:
args: --release --out dist -m crates/pymzdata/Cargo.toml
manylinux: off
rust-toolchain: stable
- name: Install pymzdata and test dependencies
run: |
python -m pip install dist/*.whl
python -m pip install 'pytest>=7' 'numpy>=1.21' 'pyteomics>=4.6' 'lxml>=4.9' 'psims>=1.3'
- name: Run Python tests
working-directory: crates/pymzdata
run: python -m pytest -v -s
test-spectra-subset:
name: mzdata-spectra
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Run cargo test
continue-on-error: true
run: |
cd crates/mzdata-spectra && cargo build --features mzsignal,nalgebra,serde
test-async-subset:
name: async_partial
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v4
- name: Install stable toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: stable
override: true
- name: Rust Cache
uses: Swatinem/rust-cache@v2
- name: Run cargo test
continue-on-error: true
uses: actions-rs/cargo@v1
with:
command: test
args: --features async_partial -- --nocapture --show-output