-
Notifications
You must be signed in to change notification settings - Fork 217
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Integration test coverage for migration of freeriders #2658
Integration test coverage for migration of freeriders #2658
Conversation
31b8882
to
1264f43
Compare
1264f43
to
cb06a2c
Compare
e364763
to
414e5b0
Compare
This test verifies that we can create a complete migration plan for a wallet with a large number of freerider UTxO entries, but with just enough non-freerider entries to enable the entire UTxO set to be migrated.
This test verifies that we can create a partial migration plan for a wallet with a large number of freerider UTxO entries, but with not quite enough non-freerider entries to enable the entire UTxO set to be migrated.
This commit just clarifies the comment and constants associated with the minting of assets in test `SHELLEY_CREATE_MIGRATION_PLAN_04`.
These tests are slow to run. If one of these tests fails, it's very unlikely to succeed when run a second time.
We do this by 1. Avoid multiple calls to waitForTxImmutability 2. Use batchSize to minting using fewer txs Now we have SHELLEY_CREATE_MIGRATION_PLAN_07 - Can create a complete migration plan for a wallet with a large number of freerider UTxO entries, but with just enough non-freerider entries to enable the entire UTxO set to be migrated. Finished in 63.8423 seconds Instead of SHELLEY_CREATE_MIGRATION_PLAN_07 - Can create a complete migration plan for a wallet with a large number of freerider UTxO entries, but with just enough non-freerider entries to enable the entire UTxO set to be migrated. Finished in 149.6189 seconds And similar for 08.
414e5b0
to
29b7c46
Compare
, expectField (#balanceSelected . #ada . #getQuantity) | ||
(`shouldBe` 257_812_500) | ||
, expectField (#balanceLeftover . #ada . #getQuantity) | ||
(`shouldBe` 29_687_500) | ||
, expectField (#balanceSelected . #assets . #getApiT) | ||
((.> 0) | ||
. Set.size | ||
. TokenMap.getAssets) | ||
, expectField (#balanceLeftover . #assets . #getApiT) | ||
((.> 0) | ||
. Set.size | ||
. TokenMap.getAssets) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice!
bors r+ |
2658: Integration test coverage for migration of freeriders r=jonathanknowles a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed:
|
bors r+ |
2658: Integration test coverage for migration of freeriders r=Anviking a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed:
|
bors r+ |
2658: Integration test coverage for migration of freeriders r=Anviking a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed: Test failure: (log) JSON encoding of ApiMaintenanceAction
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiMaintenanceAction
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiMaintenanceAction.json
JSON encoding of ApiMaintenanceActionPostData
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiMaintenanceActionPostData
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiMaintenanceActionPostData.json
JSON encoding of ApiAsset
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiAsset
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiAsset.json
Textual encoding
building of '/nix/store/3ix888hw1hg8abvpbxplpq7fzj2g60mq-cardano-wallet-core-test-unit-2021.4.28-check' timed out after 900 seconds of silence |
bors r+ |
2658: Integration test coverage for migration of freeriders r=jonathanknowles a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed: Failure: (log)
|
bors r+ |
2658: Integration test coverage for migration of freeriders r=jonathanknowles a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed: Failure: (https://hydra.iohk.io/build/6431843/nixlog/1/tail) JSON encoding of ApiTxMetadata
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiTxMetadata
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiTxMetadata.json
JSON encoding of ApiMaintenanceAction
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiMaintenanceAction
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiMaintenanceAction.json
JSON encoding of ApiMaintenanceActionPostData
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiMaintenanceActionPostData
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiMaintenanceActionPostData.json
JSON encoding of ApiAsset
allows to encode values with aeson and read them back
+++ OK, passed 100 tests.
JSON encoding of ApiAsset
produces the same JSON as is found in test/data/Cardano/Wallet/Api/ApiAsset.json
Textual encoding
building of '/nix/store/ihz8qn4fvqk0nb1glh7ymiivaz0cg15z-cardano-wallet-core-test-unit-2021.4.28-check' timed out after 900 seconds of silence |
bors r+ |
2658: Integration test coverage for migration of freeriders r=Anviking a=jonathanknowles # Issue Number ADP-840 # Overview This PR adds integration test coverage for migrations of wallets with freerider UTxO entries. In particular, we add two test cases: - [x] `CREATE_MIGRATION_PLAN_07` This test verifies that we can create a **_complete_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_just enough_** non-freerider entries to enable the entire UTxO set to be migrated. - [x] `CREATE_MIGRATION_PLAN_08` This test verifies that we can create a **_partial_** migration plan for a wallet with a large number of freerider UTxO entries, but with **_not quite enough_** non-freerider entries to enable the entire UTxO set to be migrated. In addition, this PR: - [x] Adds a synchronization lock around the `mintSeaHorseAssets` operation, as it is not safe to be called by more than one thread concurrently. Co-authored-by: Jonathan Knowles <[email protected]> Co-authored-by: Johannes Lund <[email protected]>
Build failed: Failure: (https://hydra.iohk.io/build/6432955/nixlog/1/tail) 80) CLI Specifications, SHELLEY_CLI_WALLETS, WALLETS_UTXO_02 - Utxo statistics works properly
Waited longer than 90s to resolve action: "Wallet balance is as expected".
expected: Quantity {getQuantity = 1562000000}
but got: Quantity {getQuantity = 0}
To rerun use: --match "/CLI Specifications/SHELLEY_CLI_WALLETS/WALLETS_UTXO_02 - Utxo statistics works properly/"
src/Test/Integration/Scenario/CLI/Shelley/HWWallets.hs:129:18:
81) CLI Specifications, SHELLEY_CLI_HW_WALLETS, HW_WALLETS_01x - Restoration from account public key preserves funds
Waited longer than 90s to resolve action: "Wallet balance is as expected".
expected: Quantity {getQuantity = 1000000}
but got: Quantity {getQuantity = 0}
To rerun use: --match "/CLI Specifications/SHELLEY_CLI_HW_WALLETS/HW_WALLETS_01x - Restoration from account public key preserves funds/" |
bors r+ |
Build succeeded: |
Issue Number
ADP-840
Overview
This PR adds integration test coverage for migrations of wallets with freerider UTxO entries.
In particular, we add two test cases:
CREATE_MIGRATION_PLAN_07
This test verifies that we can create a complete migration plan for a wallet with a large number of freerider UTxO entries, but with just enough non-freerider entries to enable the entire UTxO set to be migrated.
CREATE_MIGRATION_PLAN_08
This test verifies that we can create a partial migration plan for a wallet with a large number of freerider UTxO entries, but with not quite enough non-freerider entries to enable the entire UTxO set to be migrated.
In addition, this PR:
mintSeaHorseAssets
operation, as it is not safe to be called by more than one thread concurrently.