We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent e276135 commit 32861f0Copy full SHA for 32861f0
tests/integration/token_pause_transaction_e2e_test.py
@@ -62,7 +62,7 @@ def unpausable_token(env):
62
"token_id, exception, msg",
63
[
64
(None, ValueError, "token_id must be set"),
65
- (TokenId(0, 0, 99999999), PrecheckError, ResponseCode.INVALID_TOKEN_ID),
+ (TokenId(0, 0, 99999999), PrecheckError, str(ResponseCode.INVALID_TOKEN_ID)),
66
# (lazy_fixture("unpausable_token"), PrecheckError, ResponseCode.TOKEN_HAS_NO_PAUSE_KEY),
67
],
68
)
@@ -77,9 +77,13 @@ def test_pause_error_cases(env, token_id, exception, msg):
77
if token_id is not None:
78
tx.set_token_id(token_id)
79
80
- tx.freeze_with(env.client)
81
- with pytest.raises(exception, match=msg):
82
- tx.execute(env.client)
+ if exception is ValueError:
+ with pytest.raises(ValueError, match=msg):
+ tx.freeze_with(env.client)
83
+ else:
84
85
+ with pytest.raises(exception, match=msg):
86
+ tx.execute(env.client)
87
88
@mark.integration
89
class TestTokenPause:
0 commit comments