Skip to content

Commit

Permalink
formatting
Browse files Browse the repository at this point in the history
  • Loading branch information
dmoka committed Jan 3, 2025
1 parent be0598d commit d924359
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 12 deletions.
18 changes: 7 additions & 11 deletions integration-tests/src/omnipool_liquidity_mining.rs
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,6 @@ use warehouse_liquidity_mining::{
};
use xcm_emulator::TestExt;


#[macro_export]
macro_rules! assert_nft_owner {
( $coll:expr, $item: expr, $acc:expr ) => {{
Expand Down Expand Up @@ -578,15 +577,13 @@ fn add_liquidity_with_limit_and_join_farms_should_work_for_multiple_farms() {
(global_farm_2_id, yield_farm_2_id),
(global_farm_3_id, yield_farm_3_id),
];
assert_ok!(
hydradx_runtime::OmnipoolLiquidityMining::add_liquidity_and_join_farms(
RuntimeOrigin::signed(CHARLIE.into()),
farms.try_into().unwrap(),
ETH,
1_000 * UNITS,
Some(1_000 * UNITS)
)
);
assert_ok!(hydradx_runtime::OmnipoolLiquidityMining::add_liquidity_and_join_farms(
RuntimeOrigin::signed(CHARLIE.into()),
farms.try_into().unwrap(),
ETH,
1_000 * UNITS,
Some(1_000 * UNITS)
));

//Assert that the ownership of the nft should be transferred to omnipool account
let lm_account = hydradx_runtime::OmnipoolLiquidityMining::account_id();
Expand Down Expand Up @@ -2111,4 +2108,3 @@ pub fn init_stableswap() -> Result<(AssetId, AssetId, AssetId), DispatchError> {

Ok((pool_id, asset_in, asset_out))
}

2 changes: 1 addition & 1 deletion pallets/omnipool-liquidity-mining/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -969,7 +969,7 @@ pub mod pallet {
farm_entries: BoundedVec<(GlobalFarmId, YieldFarmId), T::MaxFarmEntriesPerDeposit>,
asset: T::AssetId,
amount: Balance,
min_shares_limit: Option<Balance>
min_shares_limit: Option<Balance>,
) -> DispatchResult {
ensure_signed(origin.clone())?;
ensure!(!farm_entries.is_empty(), Error::<T>::NoFarmEntriesSpecified);
Expand Down

0 comments on commit d924359

Please sign in to comment.