solana_program_runtime::invoke_context

Function mock_process_instruction

source
pub fn mock_process_instruction<F: FnMut(&mut InvokeContext<'_>), G: FnMut(&mut InvokeContext<'_>)>(
    loader_id: &Pubkey,
    program_indices: Vec<IndexOfAccount>,
    instruction_data: &[u8],
    transaction_accounts: Vec<TransactionAccount>,
    instruction_account_metas: Vec<AccountMeta>,
    expected_result: Result<(), InstructionError>,
    builtin_function: BuiltinFunctionWithContext,
    pre_adjustments: F,
    post_adjustments: G,
) -> Vec<AccountSharedData>