Skip to content

Commit

Permalink
Merge pull request #345 from davidhewitt/asan-0.17-backport
Browse files Browse the repository at this point in the history
Add a CI job running test in release mode and under address sanitizer.
  • Loading branch information
davidhewitt committed Aug 28, 2022
2 parents fb3ff8c + 5f1dc2f commit a7fa4c8
Showing 1 changed file with 26 additions and 6 deletions.
32 changes: 26 additions & 6 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ jobs:
lint:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: stable
Expand Down Expand Up @@ -48,7 +48,7 @@ jobs:
- python-version: pypy-3.8
platform: { os: "ubuntu-latest", python-architecture: "x64", rust-target: "x86_64-unknown-linux-gnu" }
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
Expand Down Expand Up @@ -90,17 +90,37 @@ jobs:
runs-on: ubuntu-latest
needs: [lint, check-msrv, examples]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- uses: messense/maturin-action@v1
with:
target: aarch64
manylinux: auto
args: --manifest-path examples/simple/Cargo.toml

address-sanitizer:
runs-on: ubuntu-22.04
needs: [lint, check-msrv, examples]
steps:
- uses: actions/checkout@v3
- uses: actions-rs/toolchain@v1
with:
toolchain: nightly
profile: minimal
components: rust-src
default: true
- uses: Swatinem/rust-cache@v2
continue-on-error: true
- run: |
pip install numpy
cargo test -Zbuild-std --target x86_64-unknown-linux-gnu --release --lib --tests
env:
RUSTFLAGS: -Zsanitizer=address
ASAN_OPTIONS: detect_leaks=0
check-msrv:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v2
with:
Expand Down Expand Up @@ -152,7 +172,7 @@ jobs:
examples:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v2
with:
Expand All @@ -177,7 +197,7 @@ jobs:
runs-on: ubuntu-latest
needs: [lint, check-msrv, examples]
steps:
- uses: actions/checkout@v2
- uses: actions/checkout@v3
- name: Set up Python
uses: actions/setup-python@v2
with:
Expand Down

0 comments on commit a7fa4c8

Please sign in to comment.