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

Better model of sudo test in examples. #316

Open
jawoznia opened this issue Mar 4, 2024 · 0 comments
Open

Better model of sudo test in examples. #316

jawoznia opened this issue Mar 4, 2024 · 0 comments
Labels

Comments

@jawoznia
Copy link
Collaborator

jawoznia commented Mar 4, 2024

          Is there any test case asserting that when we call sudo_custom, the Sudo message is generated and sent under the hood? I can imagine a situation where `#[msg(sudo)]` and `sudo_custom()` might, by mistake, operate on an Exec or Query message.

Originally posted by @kulikthebird in #301 (comment)

While testing the exec message we model the flow as:
multitest(sends message) -> contract (receives message and return custom message) -> custom module (receives and parses custom message)

In case of sudo the flow should be reversed
multitest(sends message) -> custom module -> contract (receives message and return custom message)
custom module (receives and parses custom message)

Discuss with @DariuszDepta how such flow should be modeled in multitest.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant