diff options
author | Christian Grothoff <christian@grothoff.org> | 2024-09-15 23:30:39 +0200 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2024-09-15 23:30:39 +0200 |
commit | a924a1ebec9e211be9fb1c66e452f8693df26276 (patch) | |
tree | f468388262c3a1caad0e84183a3d4e9fc9b7f584 /src | |
parent | 9ee30135f9dc2ed4f9b80a12bc928588e3b27a55 (diff) |
modernize test-20
Diffstat (limited to 'src')
-rwxr-xr-x | src/auditor/test-auditor.sh | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/src/auditor/test-auditor.sh b/src/auditor/test-auditor.sh index 53c95ff9d..80165c800 100755 --- a/src/auditor/test-auditor.sh +++ b/src/auditor/test-auditor.sh @@ -1564,7 +1564,6 @@ function test_19() { # Test where reserve closure was not done properly -# FIXME: test-20 not modernized function test_20() { echo "===========20: reserve closure missing =================" @@ -1582,21 +1581,15 @@ function test_20() { run_audit check_auditor_running - call_endpoint "reserve-not-closed-inconsistency" - call_endpoint "balances" "total_balance_reserve_not_closed" - echo -n "Testing reserve closure missing detected... " - jq -e .reserve_not_closed_inconsistency[0] \ - < "${MY_TMP_DIR}/reserve-not-closed-inconsistency.json" \ - > /dev/null \ - || exit_fail "Reserve not closed inconsistency not detected" - echo "PASS" - - AMOUNT=$(jq -r .balances[0].balance_value < "${MY_TMP_DIR}/total_balance_reserve_not_closed.json") - if [ "$AMOUNT" == "TESTKUDOS:0" ] - then - exit_fail "Reported total amount wrong: $AMOUNT" - fi + check_report \ + "reserve-not-closed-inconsistency" \ + "suppressed" "false" + echo -n "Testing balance updated correctly... " + check_not_balance \ + "total_balance_reserve_not_closed" \ + "TESTKUDOS:0" \ + "Reported total amount wrong" # Undo echo "UPDATE exchange.reserves_in SET execution_date='${OLD_TIME}',credit.val=${OLD_VAL} WHERE reserve_in_serial_id=1;" \ |