-
Notifications
You must be signed in to change notification settings - Fork 125
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
Split compose_call into two functions #706
Conversation
e0e3e85
to
7c587a7
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In the issue you say "in case multiple calls for one pallet are created, the current code is forced to get the PalletMetada each time for each call. That's not necessary."
I don't see, how you can create this scenario with the new macros. Would you call
let pallet_metadata = $node_metadata.pallet_by_name($pallet).unwrap().to_owned();
directly and then use the second macro to compose the calls?
Generally, I would propose to write a simple test, with the scenario described in #598. If it can be done nicely with the new code, then I'm fine with it.
Added an unit test in 688068a. Is that what you imagined? |
Yes. But I would also add some assertion on _call_one and _call_two. |
Cool! You're right - I fixed it in 5de32cf and moved it to the correct crate as well. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, thanks for the test :-)
closes #598