diff --git a/.travis.yml b/.travis.yml index e8710becf3..fdf11a023a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,6 +25,7 @@ addons: install: - pip3 install ed25519 pyblake2 + - pip2 install mnemonic protobuf requests script: - test "$GOAL" != "stm32" || test "$CC" != "gcc" || make vendorheader @@ -35,6 +36,7 @@ script: - test "$GOAL" != "unix" || make build_unix TREZOR_NOUI=1 - test "$GOAL" != "unix" || make test + - test "$GOAL" != "unix" || make testpy notifications: webhooks: diff --git a/tests/run_tests.sh b/tests/run_tests.sh index 3f40664d2a..4d6285bb7f 100755 --- a/tests/run_tests.sh +++ b/tests/run_tests.sh @@ -1,21 +1,26 @@ #!/bin/bash + MICROPYTHON=../vendor/micropython/unix/micropython + results=() error=0 + if [ -z "$*" ]; then list="test_*.py" else list="$*" fi + for i in $list; do - echo + echo if $MICROPYTHON $i; then - results+=("OK $i") + results+=("OK $i") else - results+=("FAIL $i") - error=1 + results+=("FAIL $i") + error=1 fi done + echo echo 'Summary:' printf '%s\n' "${results[@]}" diff --git a/tests/run_tests_python_trezor.sh b/tests/run_tests_python_trezor.sh index 4caea48621..fb924386af 100755 --- a/tests/run_tests_python_trezor.sh +++ b/tests/run_tests_python_trezor.sh @@ -59,13 +59,20 @@ for i in \ test_op_return.py \ test_zerosig.py \ ; do - if ! $PYTHON $i ; then - error=1 - break + + if $PYTHON $i; then + results+=("OK $i") + else + results+=("FAIL $i") + error=1 fi + done # kill emulator kill $UPY_PID +echo +echo 'Summary:' +printf '%s\n' "${results[@]}" exit $error