Skip to content

ATS-ACC-REC-012Abandon a draft and release its money: Capability Test Specification

Markdown

ATS-ACC-REC-012

Abandon a draft and release its money: Capability Test Specification

Markdown
  • DocumentProposed

KindAcceptance test setProduct areaAccountingModuleReconciliationRevision3

Read atservices-accounting f47cb263react-console baf6dae3

Coverage

  • Transition covered
  • Validation covered
  • Permission covered
  • Invariant covered
  • Interaction covered
  • Rule gap: FND-ACC-REC-057
  • Edge gap: FND-ACC-REC-057
  • Failure gap: FND-ACC-REC-057
  • Boundary gap: FND-ACC-REC-057
  • Concurrency gap: FND-ACC-REC-057

Test Scenarios

8 scenarios proving CAP-ACC-REC-012; 6 bound to an existing test.

01 Void reason, version and open statevalidationapinegativetest
Proves
BR-CAP-ACC-REC-012-01
Preconditions
Open and finalized examples exist.
Steps
Omit the void reason, use a stale version and void finalized state.
Expected
All invalid voids fail.
Data
No additional fixture beyond the case setup.
Bound to
Source
services-accounting:modules/reconciliation/tests/e2e/batch-lifecycle.e2e.spec.js#refuses a void without a reason with 400
02 Void releases without accountinginteractionapitest
Proves
BR-CAP-ACC-REC-012-02 BR-CAP-ACC-REC-012-03 BR-CAP-ACC-REC-012-04 BR-CAP-ACC-REC-012-07
Preconditions
A draft owns a payout, matched capture and manual fee.
Steps
Void it and place the released payout in another draft.
Expected
Holdings are released with the reason, the fee is withdrawn, capture stays unresolved and no posting is requested.
Data
No additional fixture beyond the case setup.
Bound to
Source
services-accounting:modules/reconciliation/tests/integration/services/batch-lifecycle/void-batch.integration.spec.js#releases every claim with the reason
03 Stored lifecycle transition matrixtransitionunittest
Proves
BR-CAP-ACC-REC-012-05
Preconditions
Every stored reconciliation state is represented.
Steps
Evaluate all possible state moves.
Expected
Only open-to-finalized, open-to-voided and finalized-to-reversed transitions pass.
Data
No additional fixture beyond the case setup.
Bound to
Source
services-accounting:modules/reconciliation/tests/unit/rules/transitions.spec.js#allows finalized
04 Terminal draft abandonmentinvariantapinegativetest
Proves
BR-CAP-ACC-REC-012-06
Preconditions
A voided reconciliation exists.
Steps
Edit it or add a claim.
Expected
The terminal seal refuses both changes.
Data
No additional fixture beyond the case setup.
Bound to
Source
services-accounting:modules/reconciliation/tests/integration/services/batch-lifecycle/void-batch.integration.spec.js#leaves the voided batch sealed (RHF30)
05 Void requires deletepermissionapinegativetest
Proves
BR-CAP-ACC-REC-012-08
Preconditions
The caller lacks reconciliation delete.
Steps
Attempt a draft void.
Expected
Authorization refuses the command.
Data
No additional fixture beyond the case setup.
Bound to
services-accounting:modules/reconciliation/tests/e2e/batch-lifecycle.e2e.spec.js#refuses a principal without accounting.reconciliation-batches.delete with 403
Source
services-accounting:modules/reconciliation/tests/e2e/batch-lifecycle.e2e.spec.js#refuses a principal without accounting.reconciliation-batches.delete with 403
06 Void chain frees the payout referenceinteractionapitest
Proves
AS-JNY-ACC-REC-002-02
Preconditions
A draft holds a payout.
Steps
Try payout void, void the draft, void the released payout and reuse its reference.
Expected
The held void fails, followed by successful draft and payout void and reference reuse.
Data
Use the isolated reconciliation fixture unit.
Bound to
Source
react-console:acceptance/accounting/playwright/journeys/reconciliation-close/ACT-ACC-0593.spec.ts#ACT-ACC-0593
07 Abandonment permits payout cancellationinteractionapiproposed
Proves
AS-JNY-ACC-REC-002-02 BR-CAP-ACC-REC-002-06 BR-CAP-ACC-REC-002-07
Preconditions
Use one isolated workspace with the financial records and caller roles required by the relied-on cases.
Steps
[ { "do": "Try to void a held payout, abandon its draft and repeat payout cancellation.", "expect": "The held attempt fails and the released payout can then be cancelled.", "provenance": "proposed", "source": [ "specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-012-abandon-a-draft-reconciliation-and-free-what-it-held.md", "specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-002-correct-document-or-void-a-deposit-until-it-is-reconciled.md" ] } ]
Expected
The held attempt fails and the released payout can then be cancelled.
Data
Local merchant and bank accounts, an open operational batch and distinct preparation and approval callers.
Source
specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-012-abandon-a-draft-reconciliation-and-free-what-it-held.md,specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-002-correct-document-or-void-a-deposit-until-it-is-reconciled.md
08 Abandonment and reversal retain different accountinginteractionapiproposed
Proves
BR-CAP-ACC-REC-012-02 BR-CAP-ACC-REC-012-03 BR-CAP-ACC-REC-012-04 BR-CAP-ACC-REC-012-07 BR-CAP-ACC-REC-013-03 BR-CAP-ACC-REC-013-08
Preconditions
Use one isolated workspace with the financial records and caller roles required by the relied-on cases.
Steps
[ { "do": "Abandon an open explanation and reverse a finalized explanation with the same money pattern.", "expect": "Both release holdings; only the approved explanation retains original requests and their mirrors.", "provenance": "proposed", "source": [ "specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-012-abandon-a-draft-reconciliation-and-free-what-it-held.md", "specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-013-correct-a-finalized-reconciliation-by-reversing-it-and.md" ] } ]
Expected
Both release holdings; only the approved explanation retains original requests and their mirrors.
Data
Local merchant and bank accounts, an open operational batch and distinct preparation and approval callers.
Source
specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-012-abandon-a-draft-reconciliation-and-free-what-it-held.md,specs/accounting/reconciliation/planning/capabilities/CAP-ACC-REC-013-correct-a-finalized-reconciliation-by-reversing-it-and.md

The Markdown files under specs/ in rhythmsoftware/rhythm-v2-docs are the canonical source of truth. This reader is a generated, read-only projection of them.