Skip to content

Commit

Permalink
Add check for zero in join_with_exact_pool
Browse files Browse the repository at this point in the history
  • Loading branch information
maltekliemann committed Mar 28, 2022
1 parent ef0855b commit 825152f
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions zrml/swaps/src/tests.rs
Original file line number Diff line number Diff line change
Expand Up @@ -568,6 +568,11 @@ fn pool_amount_must_not_be_zero() {
Swaps::pool_exit(alice_signed(), 0, 0, vec!(_1, _1, _1, _1)),
crate::Error::<Runtime>::MathApproximation
);

assert_noop!(
Swaps::pool_join_with_exact_pool_amount(alice_signed(), 0, ASSET_A, 0, 0,),
crate::Error::<Runtime>::MathApproximation
);
});
}

Expand Down

0 comments on commit 825152f

Please sign in to comment.