Skip to content

Avoid building wasm-bindgen-cli #687

Avoid building wasm-bindgen-cli

Avoid building wasm-bindgen-cli #687

Workflow file for this run

name: CI PR
on:
pull_request:
branches:
- main
env:
RUST_BACKTRACE: 1
jobs:
test:
name: Test Rust ${{ matrix.rust }} on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
fail-fast: false
matrix:
include:
- { rust: nightly, os: ubuntu-latest }
steps:
- uses: actions/checkout@v3
- uses: hecrj/setup-rust-action@v1
with:
rust-version: ${{ matrix.rust }}
- run: cargo test --verbose
clippy:
name: Lint with clippy
runs-on: ubuntu-latest
env:
RUSTFLAGS: -Dwarnings
steps:
- uses: actions/checkout@v3
- uses: hecrj/setup-rust-action@v1
with:
components: clippy
rust-version: nightly
- run: cargo clippy --all-targets --verbose
rustfmt:
name: Verify code formatting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: hecrj/setup-rust-action@v1
with:
components: rustfmt
- run: cargo fmt --all -- --check
doc:
name: Verify crate documentation
runs-on: ubuntu-latest
env:
RUSTFLAGS: -Dwarnings
RUSTDOCFLAGS: -Dwarnings
steps:
- uses: actions/checkout@v3
- uses: hecrj/setup-rust-action@v1
with:
rust-version: nightly
- run: cargo doc --workspace
miri:
name: Check for undefined behaviour with miri
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: hecrj/setup-rust-action@v1
with:
components: miri
rust-version: nightly
- run: cargo miri setup
- run: cargo miri test
test-python:
name: Test python bindings
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: build python bindings
uses: PyO3/maturin-action@v1
with:
working-directory: 'nemo-python'
- name: install python bindings
run: ls target/wheels/*.whl | xargs pip install
- name: run python tests
run: python -m unittest discover -s nemo-python/tests -v
pycodestyle:
name: Check python code formatting
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-python@v4
with:
python-version: '3.10'
- name: install pycodestyle
run: pip install pycodestyle
- name: run pycodestyle
run: pycodestyle nemo-python