-
Notifications
You must be signed in to change notification settings - Fork 18
37 lines (30 loc) · 1.11 KB
/
valgrind.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
on: [push, pull_request]
name: Valgrind Memory Check
jobs:
valgrind:
name: Memory Check
runs-on: ubuntu-latest
steps:
- name: Checkout sources
uses: actions/checkout@v2
- name: Install nightly toolchain
uses: actions-rs/toolchain@v1
with:
profile: minimal
toolchain: nightly
override: true
# - name: Install valgrind
# run: sudo apt install -y valgrind
- name: Install valgrind
run: |
sudo apt update && sudo apt install -y libclang-dev libc6-dbg \
&& wget -O valgrind.tar.bz2 https://sourceware.org/pub/valgrind/valgrind-3.19.0.tar.bz2 \
&& mkdir valgrind && tar -xvjf valgrind.tar.bz2 -C valgrind --strip-components=1 \
&& cd valgrind && ./configure && make && sudo make install
- name: Run cargo build
uses: actions-rs/cargo@v1
with:
command: build
args: "--example containers --features 'anyhow backtrace chrono uuid'"
- name: Run valgrind
run: valgrind --error-exitcode=1 --leak-check=full ./target/debug/examples/containers