Skip to content

Commit

Permalink
Add LSAN build to travis.
Browse files Browse the repository at this point in the history
For now it only runs test_cc and has to filter out a test which leaks.
However we will expand this over time until the entire build is LSAN clean.
  • Loading branch information
ry committed Dec 3, 2018
1 parent f25220b commit 8373046
Show file tree
Hide file tree
Showing 3 changed files with 25 additions and 8 deletions.
1 change: 1 addition & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@
/* symlink=dir
/website/* symlink=dir
/tools/clang symlink=dir
/tools/memory symlink=dir
31 changes: 23 additions & 8 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,9 +13,7 @@ env:
- RUST_BACKTRACE=1
- HOMEBREW_PATH=$HOME/homebrew/
- DENO_BUILD_ARGS="use_sysroot=false"
- DENO_BUILD_PATH=$HOME/out/Default
- CARGO_TARGET_DIR=$HOME/target
- DENO_BUILD_MODE=release
- PATH=$TRAVIS_BUILD_DIR/third_party/llvm-build/Release+Asserts/bin:$CARGO_HOME/bin:$PATH
- CCACHE_CPP2=yes
- CCACHE_SLOPPINESS=time_macros
Expand Down Expand Up @@ -89,30 +87,47 @@ before_script:
- ./tools/setup.py
script:
- |-
set -e
# Check lint and format.
set -e # Fail immediately if any of the following fail.
./tools/lint.py
./tools/test_format.py
- |-
# LSAN build of test_cc. We are in the process of getting a
# completely clean LSAN build, but it will take some work. So for now
# we just run a single test that passes under LSAN.
echo is_asan=true >> target/debug/args.gn
echo is_lsan=true >> target/debug/args.gn
DENO_BUILD_MODE=debug ./tools/build.py -j2 test_cc
ASAN_OPTIONS=detect_leaks=1 ./target/debug/test_cc
- |-
# Release build and test
bash -c "sleep 2100; pkill ninja; pkill cargo" &
./tools/build.py -j2
DENO_BUILD_MODE=release ./tools/build.py -j2
DENO_BUILD_MODE=release ./tools/test.py
- |-
# Cargo check
RUSTC_WRAPPER=sccache cargo check -j2 --release
./tools/test.py $DENO_BUILD_PATH
after_script:
- ccache --show-stats
- sccache --stop-server
after_success:
- |
# Run benchmarks and publish the result to github pages.
if [ $BENCHMARK ]; then
./tools/benchmark.py $DENO_BUILD_PATH &&
./tools/benchmark.py target/release &&
cp -r website/* gh-pages/
fi
before_deploy:
- gzip -c $DENO_BUILD_PATH/deno > $DENO_BUILD_PATH/deno_${TRAVIS_OS_NAME}_x64.gz
- gzip -c target/release/deno > target/release/deno_${TRAVIS_OS_NAME}_x64.gz
deploy:
- provider: releases
api_key: &github-token
secure: RIwv515oDcPAlEvt7uG8FeSFi6Tz6ODJUOXcFj6FYUPszxJ7Cg1kBLKln+fNW5OeOc52VsaZb/vPZ85skyEM6zk2ijL9FcSnnfNEm548w77iH6G0sk09NgBTy6KRXES6NZHD9jN1YTWYkT2G1NQi7mLqxR8a8pnWTbeK5HhtSWGsZPtXqf5iQbvnWsmKA0/w+FIgKupU0xe/qsYjh0eMLYpZDUWoKO0VxBKJ/ix5Uz91aJTjMIcHHij+ALg4pk+FkDotdyx39XB9b25KDxGuaI7NxWjSPzDxs/ZBHP6QYDLO0ti93ftvLAxRoBKPFoZrXqAu3KG9anr9WvxE40DO9OdV0VX2ZUatMUQm3DpSheN8ml2sErFqjIInqlpkdOVDYORz7FikPxkb9DKt+iuyFfxPRa4YWJv2tg8+Hy/nRCQw69OoKqrSNJ8KJDB3OjYbRBtdHz79RLJhTsGZla6RiyXfM7crR7CbFjbwdbW3Pt60t24fhvXQ0SwR0QTgzS/ieYEQHq/9GtSQA/Tn4kdIkyN6BdOMrQd/aUtgKmNdqbSlfmWGNyNZIxHdB+3RrTNT1tagkRI4UHEUfEujpIdYKwLjv0Xmi/VtTM+zOSkzHsIWGPfHBmIGnXfAItUHqivQYJ15E+dzg3T1CEbBxkDQtvwien9Fa8/pBsMkyovl8ps=
file: "$DENO_BUILD_PATH/deno_${TRAVIS_OS_NAME}_x64.gz"
file: "target/release/deno_${TRAVIS_OS_NAME}_x64.gz"
on:
tags: true
repo: denoland/deno
Expand Down
1 change: 1 addition & 0 deletions tools/memory

0 comments on commit 8373046

Please sign in to comment.