cheatcodes
Standalone Functions
reset
reset();
Takes no parameters.
get_contract_address
get_contract_address();
Takes no parameters.
set_contract_address
set_contract_address(address);
Parameters
Name | Type |
---|---|
address | AztecAddress |
get_block_number
get_block_number();
Takes no parameters.
advance_blocks_by
advance_blocks_by(blocks);
Parameters
Name | Type |
---|---|
blocks | u32 |
get_private_context_inputs
get_private_context_inputs(historical_block_number);
Parameters
Name | Type |
---|---|
historical_block_number | u32 |
get_public_context_inputs
get_public_context_inputs();
Takes no parameters.
deploy
deploy(path, initializer, args, public_keys_hash);
Parameters
Name | Type |
---|---|
path | str<N> |
initializer | str<M> |
args | [Field] |
public_keys_hash | Field |
direct_storage_write
direct_storage_write(contract_address, storage_slot, fields);
Parameters
Name | Type |
---|---|
contract_address | AztecAddress |
storage_slot | Field |
fields | [Field; N] |
create_account
create_account();
Takes no parameters.
add_account
add_account(secret, partial_address);
Parameters
Name | Type |
---|---|
secret | Field |
partial_address | PartialAddress |
derive_keys
derive_keys(secret);
Parameters
Name | Type |
---|---|
secret | Field |
set_msg_sender
set_msg_sender(msg_sender);
Parameters
Name | Type |
---|---|
msg_sender | AztecAddress |
get_msg_sender
get_msg_sender();
Takes no parameters.
get_side_effects_counter
get_side_effects_counter();
Takes no parameters.
add_authwit
add_authwit(address, message_hash);
Parameters
Name | Type |
---|---|
address | AztecAddress |
message_hash | Field |
assert_public_call_fails
assert_public_call_fails(target_address, function_selector, args);
Parameters
Name | Type |
---|---|
target_address | AztecAddress |
function_selector | FunctionSelector |
args | [Field] |
assert_private_call_fails
assert_private_call_fails(target_address, function_selector, argsHash, sideEffectsCounter, isStaticCall, isDelegateCall);
Parameters
Name | Type |
---|---|
target_address | AztecAddress |
function_selector | FunctionSelector |
argsHash | Field |
sideEffectsCounter | Field |
isStaticCall | bool |
isDelegateCall | bool |
add_nullifiers
add_nullifiers(contractAddress, nullifiers);
Parameters
Name | Type |
---|---|
contractAddress | AztecAddress |
nullifiers | [Field] |
add_note_hashes
add_note_hashes(contractAddress, inner_note_hashes);
Parameters
Name | Type |
---|---|
contractAddress | AztecAddress |
inner_note_hashes | [Field] |
oracle_reset
oracle_reset();
Takes no parameters.
oracle_get_contract_address
oracle_get_contract_address();
Takes no parameters.
oracle_set_contract_address
oracle_set_contract_address(address);
Parameters
Name | Type |
---|---|
address | AztecAddress |
oracle_get_block_number
oracle_get_block_number();
Takes no parameters.
oracle_advance_blocks_by
oracle_advance_blocks_by(blocks);
Parameters
Name | Type |
---|---|
blocks | u32 |
oracle_get_private_context_inputs
oracle_get_private_context_inputs(historical_block_number);
Parameters
Name | Type |
---|---|
historical_block_number | u32 |
oracle_get_public_context_inputs
oracle_get_public_context_inputs();
Takes no parameters.
oracle_deploy
oracle_deploy(path, initializer, args, public_keys_hash);
Parameters
Name | Type |
---|---|
path | str<N> |
initializer | str<M> |
args | [Field] |
public_keys_hash | Field |
direct_storage_write_oracle
direct_storage_write_oracle(_contract_address, _storage_slot, _values);
Parameters
Name | Type |
---|---|
_contract_address | AztecAddress |
_storage_slot | Field |
_values | [Field; N] |
oracle_create_account
oracle_create_account();
Takes no parameters.
oracle_add_account
oracle_add_account(secret, partial_address);
Parameters
Name | Type |
---|---|
secret | Field |
partial_address | PartialAddress |
oracle_derive_keys
oracle_derive_keys(secret);
Parameters
Name | Type |
---|---|
secret | Field |
oracle_get_msg_sender
oracle_get_msg_sender();
Takes no parameters.
oracle_set_msg_sender
oracle_set_msg_sender(msg_sender);
Parameters
Name | Type |
---|---|
msg_sender | AztecAddress |
oracle_get_side_effects_counter
oracle_get_side_effects_counter();
Takes no parameters.
orable_add_authwit
orable_add_authwit(address, message_hash);
Parameters
Name | Type |
---|---|
address | AztecAddress |
message_hash | Field |
oracle_assert_public_call_fails
oracle_assert_public_call_fails(target_address, function_selector, args);
Parameters
Name | Type |
---|---|
target_address | AztecAddress |
function_selector | FunctionSelector |
args | [Field] |
oracle_assert_private_call_fails
oracle_assert_private_call_fails(target_address, function_selector, argsHash, sideEffectsCounter, isStaticCall, isDelegateCall);
Parameters
Name | Type |
---|---|
target_address | AztecAddress |
function_selector | FunctionSelector |
argsHash | Field |
sideEffectsCounter | Field |
isStaticCall | bool |
isDelegateCall | bool |
oracle_add_nullifiers
oracle_add_nullifiers(contractAddress, nullifiers);
Parameters
Name | Type |
---|---|
contractAddress | AztecAddress |
nullifiers | [Field] |
oracle_add_note_hashes
oracle_add_note_hashes(contractAddress, inner_note_hashes);
Parameters
Name | Type |
---|---|
contractAddress | AztecAddress |
inner_note_hashes | [Field] |