Skip to content

Commit

Permalink
integration-flipper, mapping-integration-tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ascjones committed Nov 16, 2023
1 parent 91a740b commit 19b7d5c
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ pub mod integration_flipper {
let initial_value = client
.call(&ink_e2e::alice(), &get)
.dry_run()
.await
.await?
.return_value();

let flip = call.flip();
Expand All @@ -104,7 +104,7 @@ pub mod integration_flipper {
let flipped_value = client
.call(&ink_e2e::alice(), &get)
.dry_run()
.await
.await?
.return_value();
assert!(flipped_value != initial_value);

Expand All @@ -127,7 +127,7 @@ pub mod integration_flipper {
let initial_value = client
.call(&ink_e2e::bob(), &get)
.dry_run()
.await
.await?
.return_value();

let err_flip = call.err_flip();
Expand All @@ -136,13 +136,13 @@ pub mod integration_flipper {

assert!(matches!(
err_flip_call_result,
Err(ink_e2e::Error::<ink::env::DefaultEnvironment>::CallExtrinsic(_))
Err(ink_e2e::Error::CallExtrinsic(_))
));

let flipped_value = client
.call(&ink_e2e::bob(), &get)
.dry_run()
.await
.await?
.return_value();
assert!(flipped_value == initial_value);

Expand Down
14 changes: 7 additions & 7 deletions integration-tests/mapping-integration-tests/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ mod mapping_integration_tests {
let balance = client
.call(&ink_e2e::alice(), &get)
.dry_run()
.await
.await?
.return_value();

assert!(size.is_none());
Expand Down Expand Up @@ -218,7 +218,7 @@ mod mapping_integration_tests {
let is_there = client
.call(&ink_e2e::bob(), &contains)
.dry_run()
.await
.await?
.return_value();

assert!(is_there);
Expand Down Expand Up @@ -265,7 +265,7 @@ mod mapping_integration_tests {
let balance = client
.call(&ink_e2e::charlie(), &get)
.dry_run()
.await
.await?
.return_value();

assert_eq!(balance, Some(10_000));
Expand Down Expand Up @@ -311,7 +311,7 @@ mod mapping_integration_tests {
let balance = client
.call(&ink_e2e::dave(), &get)
.dry_run()
.await
.await?
.return_value();

assert_eq!(balance, None);
Expand Down Expand Up @@ -360,7 +360,7 @@ mod mapping_integration_tests {
let is_there = client
.call(&ink_e2e::eve(), &contains)
.dry_run()
.await
.await?
.return_value();

assert!(!is_there);
Expand Down Expand Up @@ -397,7 +397,7 @@ mod mapping_integration_tests {
let expected_insert_result = client
.call(&ink_e2e::ferdie(), &insert)
.dry_run()
.await
.await?
.return_value();
let received_insert_result =
Err(crate::mapping_integration_tests::ContractError::ValueTooLarge);
Expand All @@ -407,7 +407,7 @@ mod mapping_integration_tests {
let received_mapping_value = client
.call(&ink_e2e::ferdie(), &call.try_get_names())
.dry_run()
.await
.await?
.return_value();
let expected_mapping_value = Some(Ok(names));
assert_eq!(received_mapping_value, expected_mapping_value);
Expand Down

0 comments on commit 19b7d5c

Please sign in to comment.