1set -ex
2
3# Install Miri.
4MIRI_NIGHTLY=nightly-$(curl -s https://rust-lang.github.io/rustup-components-history/x86_64-unknown-linux-gnu/miri)
5echo "Installing latest nightly with Miri: $MIRI_NIGHTLY"
6rustup default "$MIRI_NIGHTLY"
7rustup component add miri
8
9# Run tests.
10cargo miri test
11cargo miri test --all-features
12
13# Restore old state in case Travis uses this cache for other jobs.
14rustup default nightly
15