cicd: separate sanitize workflow + manual trigger for build workflow
This commit is contained in:
parent
978a2db239
commit
bb122d6d47
3 changed files with 47 additions and 32 deletions
40
.github/workflows/sanitize.yml
vendored
Normal file
40
.github/workflows/sanitize.yml
vendored
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
name: Sunitize
|
||||
|
||||
env:
|
||||
CARGO_TERM_COLOR: always
|
||||
RUSTFLAGS: "-D warnings"
|
||||
|
||||
on:
|
||||
workflow_call:
|
||||
|
||||
jobs:
|
||||
check_undefined_behaviour:
|
||||
name: Undefined behaviour checks
|
||||
runs-on: ubuntu-latest
|
||||
env:
|
||||
TREE_SITTER: ${{ github.workspace }}/target/release/tree-sitter
|
||||
steps:
|
||||
- name: Checkout source code
|
||||
uses: actions/checkout@v3
|
||||
|
||||
- name: Install UBSAN library
|
||||
run: sudo apt-get install -y libubsan1
|
||||
|
||||
- name: Install Rust toolchain
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
|
||||
- name: Build CLI
|
||||
run: cargo build --release
|
||||
|
||||
- name: Fetch fixtures
|
||||
run: script/fetch-fixtures
|
||||
|
||||
- name: Generate fixtures
|
||||
run: script/generate-fixtures
|
||||
|
||||
- name: Run main tests with undefined behaviour sanitizer (UBSAN)
|
||||
env:
|
||||
UBSAN_OPTIONS: halt_on_error=1
|
||||
CFLAGS: -fsanitize=undefined
|
||||
RUSTFLAGS: -lubsan
|
||||
run: cargo test -- --test-threads 1
|
||||
Loading…
Add table
Add a link
Reference in a new issue