We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Hi. Amazing library! Can you please provide some insight on how to mock a canister with existing methods.
Say, I have a method
#[update] async fn do_nothing(my_arg: u64) -> Result<(), String> { Ok(()) }
How would I create a Canister mock with the method above? I've tried to use RawHandler, but cannot figure out how to transfer arguments correctly.
Canister
RawHandler
The way I want to use it later is like so:
let canister = Canister::new(mock_principals::alice()) .method("do_nothing", ...); let ctx = canister.context().inject(); ic::call_with_payment(mock_principals::alice(), "do_nothing", (1000), 100);
Is it even possible with the current implementation?
The text was updated successfully, but these errors were encountered:
Merge pull request #1 from Psychedelic/feat/runtime-stable-storage
4aaaf63
feat: impl runtime canister stable storage
No branches or pull requests
Hi. Amazing library! Can you please provide some insight on how to mock a canister with existing methods.
Say, I have a method
How would I create a
Canister
mock with the method above? I've tried to useRawHandler
, but cannot figure out how to transfer arguments correctly.The way I want to use it later is like so:
Is it even possible with the current implementation?
The text was updated successfully, but these errors were encountered: