diff options
author | Szczepan Zalega <szczepan@nitrokey.com> | 2016-10-17 20:03:51 +0200 |
---|---|---|
committer | Szczepan Zalega <szczepan@nitrokey.com> | 2016-10-19 16:35:22 +0200 |
commit | 0840919b03fa58fdfe7e0bdbf24341aef1b0b9a9 (patch) | |
tree | 07da17e8850278c2d6855e120ae8be9188cdb0df | |
parent | 0435623f8198b9a8ea6c8e64ffd5b081d4639ba8 (diff) | |
download | libnitrokey-0840919b03fa58fdfe7e0bdbf24341aef1b0b9a9.tar.gz libnitrokey-0840919b03fa58fdfe7e0bdbf24341aef1b0b9a9.tar.bz2 |
Tests cleanup: move wait function up
Signed-off-by: Szczepan Zalega <szczepan@nitrokey.com>
-rw-r--r-- | unittest/test_bindings.py | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/unittest/test_bindings.py b/unittest/test_bindings.py index 3bb8ca8..a5ef607 100644 --- a/unittest/test_bindings.py +++ b/unittest/test_bindings.py @@ -10,6 +10,13 @@ def to_hex(s): return "".join("{:02x}".format(ord(c)) for c in s) +def wait(t): + import time + msg = 'Waiting for %d seconds' % t + print(msg.center(40, '=')) + time.sleep(t) + + RFC_SECRET_HR = '12345678901234567890' RFC_SECRET = to_hex(RFC_SECRET_HR) # '12345678901234567890' @@ -486,13 +493,6 @@ def test_read_write_config(C): assert config == (255, 255, 255, False, True) -def wait(t): - import time - msg = 'Waiting for %d seconds' % t - print(msg.center(40, '=')) - time.sleep(t) - - @pytest.mark.skip(reason='Recover not implemented for NK Storage') def test_factory_reset(C): C.NK_set_debug(True) |