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

Contract already deployed #180

Merged
merged 2 commits into from
Jun 29, 2022
Merged

Contract already deployed #180

merged 2 commits into from
Jun 29, 2022

Conversation

PeterYinusa
Copy link
Contributor

Explanation:

Fixes: #160

Updates the test dapp to consume a query string parameter that describes a deployed contracts address, such as http://localhost:9011/?contract=0x7F775B6392f46Cf717aBB204557f64F68eB388c1

This change will allow us to;

  • avoid repeatedly deploying a contract when testing (manual testing)
  • deploy a contract in the test setup instead of via the browser in the test steps (e2e tests)

More information:

  • The contract address in the query string param will be applied to all contracts
  • You can override the contract address for a specific contract by deploying it

Before:

After refreshing the page, there's no way to interact with the deployed contract

before.-.contract.mov

After:

Once you add the query string param, you can interact with a deployed contract

after.-.contract.mov

Manual testing steps:

  • Without query string param: Test deploying and interacting with all contracts
  • With query string param: Test interacting with all contracts

@PeterYinusa PeterYinusa marked this pull request as ready for review June 23, 2022 22:03
@PeterYinusa PeterYinusa requested a review from a team as a code owner June 23, 2022 22:03
});
console.log(result);
const receipt = await result.wait();
console.log(receipt);
Copy link
Contributor

Choose a reason for hiding this comment

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

Are these logs intentional ?

Copy link
Contributor

@jpuri jpuri left a comment

Choose a reason for hiding this comment

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

LGTM

@PeterYinusa PeterYinusa merged commit 5ee0639 into main Jun 29, 2022
@PeterYinusa PeterYinusa deleted the contract-already-deployed branch June 29, 2022 13:52
@brad-decker brad-decker mentioned this pull request Jul 27, 2022
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.

Deployed mode
2 participants