Skip to content

Commit

Permalink
fixed tests
Browse files Browse the repository at this point in the history
  • Loading branch information
quetool committed Sep 12, 2024
1 parent 47e381a commit 172684b
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 9 deletions.
3 changes: 1 addition & 2 deletions packages/reown_sign/lib/utils/sign_api_validator_utils.dart
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,7 @@ class SignApiValidatorUtils {
if (!NamespaceUtils.isValidChainId(c)) {
throw Errors.getSdkError(
Errors.UNSUPPORTED_CHAINS,
context:
'$context, chain $c should conform to "namespace:chainId" format',
context: '$context, chain $c should conform to "CAIP-2" format',
).toSignError();
}
}
Expand Down
4 changes: 2 additions & 2 deletions packages/reown_sign/test/tests/sign_common.dart
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ void signEngineTests({
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. registerEventEmitter, chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. registerEventEmitter, chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down Expand Up @@ -186,7 +186,7 @@ void signEngineTests({
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. registerAccount, chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. registerAccount, chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down
10 changes: 5 additions & 5 deletions packages/reown_sign/test/validation_test.dart
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ void main() {
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. test, chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. test, chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down Expand Up @@ -131,7 +131,7 @@ void main() {
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. test requiredNamespace, chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. test requiredNamespace, chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down Expand Up @@ -213,7 +213,7 @@ void main() {
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down Expand Up @@ -265,7 +265,7 @@ void main() {
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down Expand Up @@ -318,7 +318,7 @@ void main() {
isA<ReownSignError>().having(
(e) => e.message,
'message',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "namespace:chainId" format',
'Unsupported chains. chain $TEST_CHAIN_INVALID_1 should conform to "CAIP-2" format',
),
),
);
Expand Down

0 comments on commit 172684b

Please sign in to comment.