mirror of
https://github.com/GaloisInc/cryptol.git
synced 2024-12-16 11:22:33 +03:00
29 lines
530 B
Bash
Executable File
29 lines
530 B
Bash
Executable File
#!/bin/bash
|
|
|
|
TEST_DIR=tests
|
|
ALL_TESTS=("modsys" "parser" "issues" "regression" "renamer" "mono-binds")
|
|
|
|
TESTS=()
|
|
|
|
if [ $# == 0 ]; then
|
|
declare -a TESTS
|
|
for i in ${!ALL_TESTS[*]}; do
|
|
TESTS[i]="$TEST_DIR/${ALL_TESTS[i]}"
|
|
done
|
|
else
|
|
TESTS=("$@")
|
|
fi
|
|
|
|
GHC_VERSION=$(ghc --numeric-version)
|
|
|
|
if [ ${GHC_VERSION}x == "x" ]; then
|
|
echo Failed to guess version of GHC.
|
|
exit 1
|
|
fi
|
|
|
|
CRY=$(find dist-newstyle -name cryptol -type f | grep $GHC_VERSION)
|
|
|
|
cabal new-run cryptol-test-runner -- -c $CRY --ignore-expected ${TESTS[*]}
|
|
|
|
|