diff --git a/python/src/trezorlib/device.py b/python/src/trezorlib/device.py index 97b42297c..63f04d5cd 100644 --- a/python/src/trezorlib/device.py +++ b/python/src/trezorlib/device.py @@ -175,6 +175,7 @@ def recover( warnings.warn( "Use type=RecoveryType.DryRun instead!", DeprecationWarning, + stacklevel=3, ) if type is not None: diff --git a/tests/device_tests/reset_recovery/test_recovery_bip39_dryrun.py b/tests/device_tests/reset_recovery/test_recovery_bip39_dryrun.py index 7fc6c54eb..a08769cd8 100644 --- a/tests/device_tests/reset_recovery/test_recovery_bip39_dryrun.py +++ b/tests/device_tests/reset_recovery/test_recovery_bip39_dryrun.py @@ -94,7 +94,10 @@ def test_invalid_seed_core(client: Client): IF = InputFlowBip39RecoveryDryRunInvalid(client) client.set_input_flow(IF.get()) with pytest.raises(exceptions.Cancelled): - return device.recover(client, dry_run=True) + return device.recover( + client, + type=messages.RecoveryType.DryRun, + ) @pytest.mark.setup_client(uninitialized=True) diff --git a/tests/device_tests/reset_recovery/test_recovery_slip39_advanced_dryrun.py b/tests/device_tests/reset_recovery/test_recovery_slip39_advanced_dryrun.py index b8261effc..66d6ee82a 100644 --- a/tests/device_tests/reset_recovery/test_recovery_slip39_advanced_dryrun.py +++ b/tests/device_tests/reset_recovery/test_recovery_slip39_advanced_dryrun.py @@ -50,7 +50,7 @@ def test_2of3_dryrun(client: Client): passphrase_protection=False, pin_protection=False, label="label", - dry_run=True, + type=messages.RecoveryType.DryRun, ) # Dry run was successful @@ -74,5 +74,5 @@ def test_2of3_invalid_seed_dryrun(client: Client): passphrase_protection=False, pin_protection=False, label="label", - dry_run=True, + type=messages.RecoveryType.DryRun, ) diff --git a/tests/device_tests/reset_recovery/test_recovery_slip39_basic_dryrun.py b/tests/device_tests/reset_recovery/test_recovery_slip39_basic_dryrun.py index 0575828fe..0d424cde1 100644 --- a/tests/device_tests/reset_recovery/test_recovery_slip39_basic_dryrun.py +++ b/tests/device_tests/reset_recovery/test_recovery_slip39_basic_dryrun.py @@ -46,7 +46,7 @@ def test_2of3_dryrun(client: Client): passphrase_protection=False, pin_protection=False, label="label", - dry_run=True, + type=messages.RecoveryType.DryRun, ) # Dry run was successful @@ -70,5 +70,5 @@ def test_2of3_invalid_seed_dryrun(client: Client): passphrase_protection=False, pin_protection=False, label="label", - dry_run=True, + type=messages.RecoveryType.DryRun, )