Below are test cases used when testing the Conditional Negative Balances branch and identify some combinations of settings that should be tested when changes are made to billing.
Note: tested with negative balance settings unset and with Prohibit Negative Balances (default) setting set to False.
Expected Behavior: Produces negative balance in the amount of 29.99
Expected Behavior: $0 balance on transaction. No history of the transaction visible to the user through the GUI.
Relevant settings: Prohibit Negative Balances (default) set to True.
Expected Behavior: $0 balance on the transaction.
Relevant settings: Prohibit Negative Balances (default) set to True.
Expected behavior: $0 balance on the transaction
Expected behavior: $0 balance on the transaction
Relevant Settings: Void overdue fines when item is marked lost is set to True; Restore overdues on lost item return is set to True; Generate new overdues on lost item return is set to True; Prohibit negative balance (default) is set to True
Due date for transaction is one month ago. Overdue fines have accrued (in my example, $1.35), but have not yet reached the maxfine rate for the transaction (in my example, $3.00).
Expected Behavior: Zero balance on the transaction. $11.40 is adjusted on the item return ($10.00 in remaining lost materials fee + $1.35 in reinstated overdues + $.05 in new overdue fine generated upon lost item return)
Relevant Settings: Void overdue fines when item is marked lost is set to True; Restore overdues on lost item return is set to True; Generate new overdues on lost item return is set to True; Prohibit negative balance (default) is set to True
Due date for item is a year ago. Overdue fines have accrued ($3 in my example, reaching the max fine limit)
Expected behavior: $2 balance on transaction for the remaining overdue fines. $23 has been adjusted upon the lost item return
Relevant Settings: Void overdue fines when item is marked lost set to True; Restore overdues on lost item return set to True; Generate new overdues on lost item return Set to True; Prohibit negative balance (default) is unset
Overdue fines had accrued on transaction ($1.75 in my example) when it was marked lost, but had not yet reached the max fine rate for the transaction ($3.00 in my example).
Expected behavior: The negative balance on the transaction will equal the partial payment minus the max fine rate, for a total of -$7.00 in my example.
Relevant settings - Void overdue fines when item is marked lost is set to True; Restore overdues on lost item return is set to True; Generate new overdues on lost item return is set to True; Prohibit negative balance (default) – True
Overdue fines had accrued on transaction ($2.45 in my example) when it was marked lost, but had not yet reached the max fine rate for the transaction ($3.00 in my example).
Expected behavior: The balance on the transaction is zero.The adjusted payment on the transaction should equal the remaining lost materials fee ($12) plus the max fine rate ($3). In my example, a total of $15 is adjusted.
Relevant Settings: Negative balance interval set to 1 hour; Prohibit negative balance (default) set to True
Expected behavior: A negative balance in the amount of the lost materials fee should be remaining on the first item returned. A zero balance should be remaining on the second items returned.
Relevant Settings: Prohibit negative balance set to true; No interval settings
Expected/Desired behavior: No negative balance should be produced. Current behavior: Negative balance is produced.
Relevant settings: Prohibit negative balances (default) set to True
Expected behavior zero balance on the transaction.
Relevant settings Prohibit negative balances on bills for lost materials set to True; all other negative balance settings unset.
Repeat test 1 and test 12.
Expected behavior:
Relevant settings – Prohibit negative balances on bills for overdue materials set to True; All other negative balance settings unset.
Repeat test 1 and test 12.
Expected behavior: