enforce min & max lease period

This commit is contained in:
2022-09-05 22:17:55 +00:00
parent f1ea4edca8
commit 8711758f20
4 changed files with 33 additions and 9 deletions

View File

@@ -4,13 +4,17 @@
HERE=$(cd $(dirname $BASH_SOURCE) && pwd)
source $HERE/testutil.sh
# echo $BOB
# cosmos-testd q cosmostest show-auction $(get_last_auction_index) | jq
# exit 0
cosmos-testd tx cosmostest new-auction asdf asdf 200 token $(now + 3500) \
-y --from bob \
| expect_fail "Can't create auction below min lease period"
cosmos-testd tx cosmostest new-auction asdf asdf 200 token $(now + 8200000) \
-y --from bob \
| expect_fail "Can't create auction above max lease period"
before=$(get_balance $BOB token)
cosmos-testd tx cosmostest new-auction asdf asdf 200 token $(now + 100) \
cosmos-testd tx cosmostest new-auction asdf asdf 200 token $(now + 3700) \
-y --from bob \
| expect_success "New auction is created"