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.
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.
_Originally posted by @kulikthebird in https://github.com/CosmWasm/sylvia/pull/301#discussion_r1486041632_
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 reversedmultitest
(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.