From 702b196000e26e2c706f1ae53f9fa8b0d02a50a3 Mon Sep 17 00:00:00 2001 From: Dan Wells Date: Thu, 20 Jul 2017 18:10:15 -0400 Subject: [PATCH] LP#1689656 Add test for manual adjustment of negative balance Without the fix in LP#1689656, this test fails. Signed-off-by: Dan Wells --- .../src/perlmods/live_t/09-lp1198465_neg_balances.t | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/live_t/09-lp1198465_neg_balances.t b/Open-ILS/src/perlmods/live_t/09-lp1198465_neg_balances.t index 33b4023e41..318f52ca92 100644 --- a/Open-ILS/src/perlmods/live_t/09-lp1198465_neg_balances.t +++ b/Open-ILS/src/perlmods/live_t/09-lp1198465_neg_balances.t @@ -1,6 +1,6 @@ #!perl -use Test::More tests => 132; +use Test::More tests => 133; diag("Test features of Conditional Negative Balances code."); @@ -477,6 +477,23 @@ is( ); +### adjust to zero, manually +$apputils->simplereq( + 'open-ils.circ', + 'open-ils.circ.money.billable_xact.adjust_to_zero', + $script->authtoken, + [$xact_id] +); + +### verify 2nd ending state +$summary = fetch_billable_xact_summary($xact_id); +is( + $summary->balance_owed, + '0.00', + 'Case 13 (bonus): Patron has a balance of 0.00 (after manual adjustment of negative balance)' +); + + ############################## # 14. RERUN of Case 1. No Prohibit Negative Balance Settings Are Enabled, Payment Made # SETTINGS: Prohibit negative balances on bills for overdue materials -- 2.11.0