Skip to content

Commit

Permalink
adding route spawn test
Browse files Browse the repository at this point in the history
  • Loading branch information
dzmitry-lahoda committed Mar 12, 2024
1 parent df3aadb commit 56e4657
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion contracts/cosmwasm/order/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -206,7 +206,7 @@ impl OrderContract<'_> {
},
];
let cvm = wasm_execute(contract, &cvm, funds)?;
trust_fill();
//trust_fill();
Ok(Response::default().add_message(cvm))
}

Expand Down
9 changes: 5 additions & 4 deletions contracts/cosmwasm/order/src/simulator.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,10 +12,11 @@ use crate::SolvedOrder;

/// given expected output amount and list of orders and CVM program, produce fill in of orders
/// return filling amounts for all orders from program, which may or may not lead to full fill
pub fn verify(route: CvmProgram, out_asset: &AssetItem, out_asset:&AssetItem, orders: Vec<SolvedOrder>) -> Result<Vec<Filling>, StdError> {
match route.instructions[0] {

}
pub fn verify(route: CvmProgram, in_asset: &AssetItem, out_asset:&AssetItem, orders: Vec<SolvedOrder>) -> Result<Vec<Filling>, StdError> {
// match route.instructions[0] {
// cvm_runtime::Instruction::Spawn { network_id, salt, assets, program } => todo!(),
// }
panic!()
}

/// All orders amounts aggregated into common pool.
Expand Down

0 comments on commit 56e4657

Please sign in to comment.