feat: add automatic deployment for MBSM in blueprint test utils #509
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This pull request includes several important changes to the
blueprint-test-utils
module, primarily focusing on enhancing the functionality of handling Master Blueprint Service Manager (MBSM) revisions and improving transaction handling.Enhancements to MBSM handling:
blueprint-test-utils/src/tangle/transactions.rs
: Added a new functiondeploy_new_mbsm_revision
to deploy a new MBSM revision and return the result. This function includes detailed steps for deploying the contract and updating the service manager.blueprint-test-utils/src/tangle/transactions.rs
: Added a new functionget_latest_mbsm_revision
to fetch the latest revision of the MBSM from storage.blueprint-test-utils/src/test_ext.rs
: Modifiednew_test_ext_blueprint_manager
to check if the MBSM is already deployed and deploy a new revision if not.Improvements to transaction handling:
blueprint-test-utils/src/tangle/transactions.rs
: Modifiedwait_for_in_block_success
to returnExtrinsicEvents
instead of a simple result, providing more detailed information on transaction success.Additional imports:
blueprint-test-utils/src/tangle/transactions.rs
: Added necessary imports for new functionalities, includingReceiptResponse
,TransactionBuilder
,PrivateKeySigner
, and others.blueprint-test-utils/src/test_ext.rs
: Added imports forhex
anddebug
to support new MBSM handling logic. [1] [2]Closes #498