Skip to content
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

Use CLI to deploy test contract #589

Merged
merged 1 commit into from
Mar 10, 2022

Conversation

nguyer
Copy link
Contributor

@nguyer nguyer commented Mar 8, 2022

This PR changes the E2E tests to use the new FireFly CLI feature to deploy contracts, rather than having deployment code baked in to the E2E tests directly.

Depends on hyperledger/firefly-cli#151

Signed-off-by: Nicko Guyer <nicko.guyer@kaleido.io>
@codecov-commenter
Copy link

Codecov Report

Merging #589 (467894c) into main (00fda51) will not change coverage.
The diff coverage is n/a.

Impacted file tree graph

@@            Coverage Diff            @@
##              main      #589   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          303       303           
  Lines        17437     17437           
=========================================
  Hits         17437     17437           

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 00fda51...467894c. Read the comment docs.

@nguyer
Copy link
Contributor Author

nguyer commented Mar 8, 2022

Note: this PR will fail until the CLI version v0.0.45 actually exists. We'll need to merge hyperledger/firefly-cli#151 and cut a new release of the CLI before re-running the checks on this PR

if [ "$TEST_SUITE" == "TestEthereumE2ESuite" ]; then
prefix='contract address: '
output=$($CLI deploy $STACK_NAME ../data/simplestorage/simple_storage.json | grep address)
CONTRACT_ADDRESS=${output#"$prefix"}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Feels slightly fragile to parse this output, but if it works...

@nguyer nguyer merged commit e7c080f into hyperledger:main Mar 10, 2022
@nguyer nguyer deleted the cli-contract-deployment branch March 10, 2022 20:10
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants