Merge branch 'master' into no-fallible-casts

This commit is contained in:
daniel
2020-11-15 13:38:12 +01:00
2 changed files with 25 additions and 1 deletions

View File

@@ -3,4 +3,7 @@ rust:
- stable - stable
- beta - beta
- nightly - nightly
git:
depth: 10
after_success:
./.travis_bench.sh

21
.travis_bench.sh Executable file
View File

@@ -0,0 +1,21 @@
#!/usr/bin/env bash
# Clone the repository
REMOTE_URL="$(git config --get remote.origin.url)";
cd ${TRAVIS_BUILD_DIR}/.. && \
git clone ${REMOTE_URL} "${TRAVIS_REPO_SLUG}-bench" && \
cd "${TRAVIS_REPO_SLUG}-bench" && \
# Bench master
git checkout master && \
cargo bench -- --noplot --save-baseline before && \
# Bench current branch
git checkout ${TRAVIS_COMMIT} && \
cargo bench -- --noplot --save-baseline after && \
# Install https://github.com/BurntSushi/critcmp
cargo install critcmp --force && \
# Compare the two generated benches
critcmp before after;