tests: update how tests are being run

This commit is contained in:
Pavol Rusnak 2017-12-19 19:32:07 +01:00
parent eff3ce2aa8
commit a9870b9e0e
No known key found for this signature in database
GPG Key ID: 91F3B339B9A02A3D
3 changed files with 2 additions and 40 deletions

1
tests/.gitignore vendored
View File

@ -1 +0,0 @@
device_tests/

View File

@ -1,37 +0,0 @@
#!/bin/bash
if [ \! -d device_tests ]; then
curl -s -L https://github.com/trezor/python-trezor/archive/master.tar.gz | tar -xvz --strip-components=2 python-trezor-master/tests/device_tests
fi
cd device_tests
pytest \
-k-multisig \
--ignore test_bip32_speed.py \
--ignore test_cosi.py \
--ignore test_debuglink.py \
--ignore test_msg_applysettings.py \
--ignore test_msg_changepin.py \
--ignore test_msg_clearsession.py \
--ignore test_msg_ethereum_signmessage.py \
--ignore test_msg_ethereum_signtx.py \
--ignore test_msg_ethereum_verifymessage.py \
--ignore test_msg_getaddress_show.py \
--ignore test_msg_loaddevice_xprv.py \
--ignore test_msg_nem_getaddress.py \
--ignore test_msg_nem_signtx.py \
--ignore test_msg_ping.py \
--ignore test_msg_recoverydevice_dryrun.py \
--ignore test_msg_recoverydevice.py \
--ignore test_msg_resetdevice_skipbackup.py \
--ignore test_msg_signmessage_segwit_native.py \
--ignore test_msg_signmessage_segwit.py \
--ignore test_msg_signtx_bch.py \
--ignore test_msg_signtx_zcash.py \
--ignore test_msg_verifymessage_segwit_native.py \
--ignore test_msg_verifymessage_segwit.py \
--ignore test_multisig_change.py \
--ignore test_multisig.py \
--ignore test_protect_call.py \
--ignore test_protection_levels.py

View File

@ -9,10 +9,10 @@ sleep 1
# run tests
cd ../tests
error=0
if ! TREZOR_TRANSPORT_V1=0 ./run_tests_device.sh; then
if ! TREZOR_TRANSPORT_V1=0 pytest -k 'not skip_t2' --pyargs trezorlib.tests.device_tests ; then
error=1
fi
if ! TREZOR_TRANSPORT_V1=1 ./run_tests_device.sh; then
if ! TREZOR_TRANSPORT_V1=1 pytest -k 'not skip_t2' --pyargs trezorlib.tests.device_tests ; then
error=1
fi
kill $upy_pid