tests: update tests, try running functional tests in travis

pull/25/head
Pavol Rusnak 7 years ago
parent 9587563c77
commit 87f20bac29
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D

@ -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:

@ -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[@]}"

@ -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

Loading…
Cancel
Save