From ec84f4b8413220f30b5aaa1dcda9968f97b53c91 Mon Sep 17 00:00:00 2001 From: "Kevin R. Thornton" Date: Mon, 18 Jul 2022 16:22:16 -0700 Subject: [PATCH] chore: add cargo-valgrind CI workflow --- .github/workflows/valgrind.yml | 38 ++++++++++++++++++++++++++++++++++ 1 file changed, 38 insertions(+) create mode 100644 .github/workflows/valgrind.yml diff --git a/.github/workflows/valgrind.yml b/.github/workflows/valgrind.yml new file mode 100644 index 000000000..f575f110b --- /dev/null +++ b/.github/workflows/valgrind.yml @@ -0,0 +1,38 @@ +on: + push: + branches: [main, dev] + pull_request: + +name: valgrind + +jobs: + cargo-valgrind: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest] + rust: + - stable + steps: + - name: Cancel Previous Runs + uses: styfle/cancel-workflow-action@0.6.0 + with: + access_token: ${{ secrets.GITHUB_TOKEN }} + + - uses: actions/checkout@v2 + with: + token: ${{ secrets.GITHUB_TOKEN }} + submodules: recursive + - uses: actions-rs/toolchain@v1 + with: + toolchain: ${{ matrix.rust }} + override: true + - uses: Swatinem/rust-cache@v1 + - run: sudo apt-get update -y + if: matrix.os == 'ubuntu-latest' + - run: sudo apt-get install -y valgrind + if: matrix.os == 'ubuntu-latest' + - run: cargo install cargo-valgrind + - name: run cargo valgrind + run: | + cargo valgrind test --all-features