From c4a2696ee556ca7ae98a893036eaf6d9d005492c Mon Sep 17 00:00:00 2001 From: Szczepan Zalega Date: Tue, 9 Aug 2016 17:19:56 +0200 Subject: Fixed test with getting random OTP codes Signed-off-by: Szczepan Zalega --- unittest/test_bindings.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'unittest') diff --git a/unittest/test_bindings.py b/unittest/test_bindings.py index 7b16a46..f94b859 100644 --- a/unittest/test_bindings.py +++ b/unittest/test_bindings.py @@ -396,6 +396,8 @@ def test_get_OTP_codes(C): def test_get_OTP_code_from_not_programmed_slot(C): + assert C.NK_first_authenticate(DefaultPasswords.ADMIN, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK + assert C.NK_write_config(255, 255, 255, False, True, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK assert C.NK_first_authenticate(DefaultPasswords.ADMIN, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK assert C.NK_erase_hotp_slot(0, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK assert C.NK_first_authenticate(DefaultPasswords.ADMIN, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK @@ -463,7 +465,6 @@ def wait(t): time.sleep(t) -# @pytest.mark.skip() def test_factory_reset(C): C.NK_set_debug(True) assert C.NK_first_authenticate(DefaultPasswords.ADMIN, DefaultPasswords.ADMIN_TEMP) == DeviceErrorCode.STATUS_OK @@ -483,6 +484,7 @@ def test_factory_reset(C): assert C.NK_lock_device() == DeviceErrorCode.STATUS_OK +@pytest.mark.skip(reason='Experimental') def test_clear(C): d = 'asdasdasd' print(d) -- cgit v1.2.3