diff --git a/tests/test_tx.py b/tests/test_tx.py index 9f871c92a0fe09620f14471ae41570c4541c8609..e294d67a344fe7cb93088f73ab5f6a814d53cc88 100644 --- a/tests/test_tx.py +++ b/tests/test_tx.py @@ -23,6 +23,7 @@ from silkaj.money import UDValue from silkaj.cli import cli from silkaj.constants import ( MINIMAL_ABSOLUTE_TX_AMOUNT, + MINIMAL_RELATIVE_TX_AMOUNT, FAILURE_EXIT_STATUS, CENT_MULT_TO_UNIT, ) @@ -169,6 +170,12 @@ def test_tx_passed_amount_cli(): assert "Error: Invalid value for '--amount'" in result.output assert result.exit_code == 2 + result = CliRunner().invoke( + cli, ["tx", "-r", "A", "-d", MINIMAL_RELATIVE_TX_AMOUNT - 0.0000001] + ) + assert "Error: Invalid value for '--amountUD'" in result.output + assert result.exit_code == 2 + result = CliRunner().invoke(cli, ["tx", "-r", "A", "-a", 1, "-a", 2]) assert ( "Error: The number of passed recipients is not the same as the passed amounts."