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

Cross-contract unit test PoV #1358

Closed
wants to merge 4 commits into from

Conversation

h4x3rotab
Copy link

@h4x3rotab h4x3rotab commented Aug 17, 2022

A work-in-progress PoV of Green's idea: Supercolony-net/openbrush-contracts#136 (comment)

  • Enable the entry points (deploy & call) in unit tests
  • Contract registry to track entrypoints, code hashes, and the account id
  • Call stack management in the offchain env
  • Pass the examples/delegator unit test
  • Error & revert handling
  • Compatible with on-chain api (minor change)

Emulate unimplemented offchain apis:

  • decode_input
  • return_value (changed Never return type to ())
  • set_code_hash
  • invoke_contract (changed to two-stage commit: _begin & _end(), without error handling)
  • invoke_contract_delegate
  • instantiate_contract (changed to two-stage commit: _begin & _end(), without error handling)
  • is_contract
  • caller_is_origin
  • code_hash
  • own_code_hash

@h4x3rotab h4x3rotab marked this pull request as draft August 17, 2022 20:17
@h4x3rotab
Copy link
Author

h4x3rotab commented Oct 18, 2022

Closing in favor of Supercolony's more mature work: Supercolony-net#4

@h4x3rotab h4x3rotab closed this Oct 18, 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.

None yet

1 participant