feat(tests/lean/run): add test_single script that sets the LEAN_PATH
Signed-off-by: Leonardo de Moura <leonardo@microsoft.com>
This commit is contained in:
parent
ec18bd93f9
commit
cf28981f45
2 changed files with 17 additions and 1 deletions
|
@ -46,7 +46,7 @@ FOREACH(T ${LEANRUNTESTS})
|
|||
GET_FILENAME_COMPONENT(T_NAME ${T} NAME)
|
||||
add_test(NAME "leanruntest_${T_NAME}"
|
||||
WORKING_DIRECTORY "${LEAN_SOURCE_DIR}/../tests/lean/run"
|
||||
COMMAND "${CMAKE_CURRENT_BINARY_DIR}/lean" ${T_NAME})
|
||||
COMMAND "./test_single.sh" "${CMAKE_CURRENT_BINARY_DIR}/lean" ${T_NAME})
|
||||
ENDFOREACH(T)
|
||||
|
||||
# LEAN INTERACTIVE TESTS
|
||||
|
|
16
tests/lean/run/test_single.sh
Executable file
16
tests/lean/run/test_single.sh
Executable file
|
@ -0,0 +1,16 @@
|
|||
#!/usr/bin/env bash
|
||||
if [ $# -ne 2 ]; then
|
||||
echo "Usage: test_single.sh [lean-executable-path] [file]"
|
||||
exit 1
|
||||
fi
|
||||
ulimit -s 8192
|
||||
LEAN=$1
|
||||
export LEAN_PATH=../../../library/standard:.
|
||||
f=$2
|
||||
echo "-- testing $f"
|
||||
if $LEAN $f; then
|
||||
echo "-- checked"
|
||||
else
|
||||
echo "failed $f"
|
||||
exit 1
|
||||
fi
|
Loading…
Reference in a new issue