From 5f7391386cb30cde52296d3ffefa525f1da17e94 Mon Sep 17 00:00:00 2001 From: parketh Date: Fri, 5 Apr 2024 17:47:00 +0100 Subject: [PATCH] test: update actions --- src/helpers/actions.cairo | 3 +++ src/helpers/actions/loan_receiver.cairo | 14 ++++++++++++++ 2 files changed, 17 insertions(+) create mode 100644 src/helpers/actions/loan_receiver.cairo diff --git a/src/helpers/actions.cairo b/src/helpers/actions.cairo index db43373..3e312dd 100644 --- a/src/helpers/actions.cairo +++ b/src/helpers/actions.cairo @@ -1,2 +1,5 @@ pub mod market_manager; pub mod token; +pub mod fee_controller; +pub mod loan_receiver; +pub mod quoter; diff --git a/src/helpers/actions/loan_receiver.cairo b/src/helpers/actions/loan_receiver.cairo new file mode 100644 index 0000000..6b0b470 --- /dev/null +++ b/src/helpers/actions/loan_receiver.cairo @@ -0,0 +1,14 @@ +// Core lib imports. +use starknet::ContractAddress; + +// Local imports. +use haiko_lib::interfaces::ILoanReceiver::{ILoanReceiverDispatcher, ILoanReceiverDispatcherTrait}; + +// External imports. +use snforge_std::{declare, ContractClassTrait, start_prank, stop_prank, CheatTarget}; + +pub fn deploy_loan_receiver(market_manager: ContractAddress) -> ILoanReceiverDispatcher { + let contract = declare("LoanReceiver"); + let contract_address = contract.deploy(@array![market_manager.into()]).unwrap(); + ILoanReceiverDispatcher { contract_address } +} \ No newline at end of file