forked from foundry-rs/starknet-foundry
-
Notifications
You must be signed in to change notification settings - Fork 0
Description
Select Tool
snforge
Requested Feature
We should add support for tests like the following:
// This example was generated automatically by snforge.
#[test]
fn test_increase_balance() {
let contract_address = deploy_contract("HelloStarknet");
let dispatcher = IHelloStarknetDispatcher { contract_address };
let balance_before = dispatcher.get_balance();
assert(balance_before == 0, 'Invalid balance');
dispatcher.increase_balance(42);
let balance_after = dispatcher.get_balance();
assert(balance_after == 42, 'Invalid balance');
}
Right know, calling this test fails because some cheatcodes are not implemented.
[FAIL] hello_starknet_integrationtest::test_contract::test_increase_balance
Failure data:
"invalid selector: declare"
Solving this issue implies modifying some cheatcodes (declare
/deploy
), as well as the call_contract
syscall.
Metadata
Metadata
Assignees
Labels
No labels