30 lines
508 B
Bash
Executable File
30 lines
508 B
Bash
Executable File
#!/bin/bash
|
|
set -euo pipefail
|
|
|
|
# Determine configuration
|
|
if [ "$TRAVIS_OS_NAME" == osx ]; then
|
|
FOREIGN_TARGET=i686-apple-darwin
|
|
else
|
|
FOREIGN_TARGET=i686-unknown-linux-gnu
|
|
fi
|
|
|
|
# Prepare
|
|
echo "Build and install miri"
|
|
./miri build --all-features --all-targets
|
|
./miri install
|
|
echo
|
|
|
|
# Test
|
|
function run_tests {
|
|
./miri test
|
|
test-cargo-miri/run-test.py
|
|
}
|
|
|
|
echo "Test host architecture"
|
|
run_tests
|
|
echo
|
|
|
|
echo "Test foreign architecture ($FOREIGN_TARGET)"
|
|
MIRI_TEST_TARGET="$FOREIGN_TARGET" run_tests
|
|
echo
|