TC-BIL-007: Discounts, Adjustments & Void
🆕 New on stage — 2026-06-29 → 2026-07-01. This TC covers the invoice-discount and void features shipped after the prior guide freeze: the Apply-Discount control + discount line rendering (#494), ₱0 fully-discounted invoices no longer hidden from the list (#495), the discount cap now counting only settled allocations (#497/#498), and void lifted to all invoice sources — dues, event, manual (#503). See the Test Plan banners and the Jun 29 / Jul 1 release notes.
Module: Billing & Invoicing — Discounts / Void
Primary Test User: treasurer@demo.membervu.com / Treasurer123! (Finance Manager)
Priority: P1 (money-adjacent — discount cap correctness and void guards)
Objectives
- Apply a discount (PERCENTAGE or FIXED) to an OUTSTANDING invoice and confirm a discount line renders with the balance dropping by the exact amount.
- Fully discount an invoice to ₱0 and confirm it still appears in the invoice list (not silently hidden).
- Confirm the discount cap counts only SETTLED allocations — a
PENDING/UNDER_REVIEWallocation must not inflateamountPaidCentsor let a discount slip below the genuinely-paid amount. - Void an invoice from each source — dues, event, manual — and confirm the action is available and succeeds for all three (subject to the refund-first guard on
SUCCEEDEDpayment allocations).
Scenario summary
| ID | Scenario | Key data assertion |
|---|---|---|
| BIL7-01 | Apply PERCENTAGE discount | POST /api/billing/admin/invoices/:invoiceId/discount returns 200; invoice amountCents drops to the exact net; a discount line/badge with reason is visible on detail; originalAmountCents is preserved. |
| BIL7-02 | Apply FIXED discount | Balance drops by exactly the fixed cents amount, not a rounded/approximate figure. |
| BIL7-03 | Fully-discounted ₱0 invoice still listed | After discounting to ₱0, the invoice remains in GET /api/billing/invoices/tenant results and is visible in the admin invoice list UI — not filtered out. |
| BIL7-04 | Discount cap ignores PENDING allocation | With a PENDING/UNDER_REVIEW manual-payment allocation on the invoice, a discount that would take net below the settled paid amount is rejected 409; a discount that only conflicts with the (uncounted) pending amount succeeds. |
| BIL7-05 | Void a DUES-source invoice | POST /api/billing/admin/invoices/:invoiceId/void → 200, status VOID. |
| BIL7-06 | Void an EVENT-source invoice | Same endpoint succeeds for an event-sourced invoice — no source-based rejection. |
| BIL7-07 | Void a MANUAL/OTHER-source invoice | Same endpoint succeeds for a manually-created invoice. |
| BIL7-08 | Void blocked on SUCCEEDED payment | Voiding an invoice with a SUCCEEDED payment allocation is rejected — refund-first guard still applies regardless of source. |
➡️ Full click-by-click steps: TC-BIL-007 (Detailed).