The Wayback Machine - https://web.archive.org/web/20201117023854/https://github.com/maticnetwork/contracts/issues/134
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

Refactor test suite #134

Open
atvanguard opened this issue Nov 4, 2019 · 0 comments
Open

Refactor test suite #134

atvanguard opened this issue Nov 4, 2019 · 0 comments
Assignees

Comments

@atvanguard
Copy link
Contributor

@atvanguard atvanguard commented Nov 4, 2019

There are some things in test suite that could cause us to overlook some test failures (false positives - positive in this context meaning, a test passes).

  1. Don't use accounts[0] and accounts[1] to run tests.

    • Since these accounts contain ether on genesis, some assertions on their account balances become infeasible.
    • Since these accounts are used by default to deploy contracts, using them within the tests might give them extra privileges. e.g. a method ACLed on onlyOwner will succeed even if that wasn't the intention.
  2. Use HDwalletProvider to instantiate web3 instead of assuming unlocked accounts on ganache / bor.

    • This will enable us to run the test suite against any network. e.g. for testing devnets
  3. Deprecate utils.startExitForErc20PredicateLegacy, utils.startExitNew and any other duplicated flavours of calling exit functions from the tests.

  4. Delete /test-v1. Make sure to migrate any tests before deleting it though.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
2 participants
You can’t perform that action at this time.