010 — should calculate positive difference when revenues exceed costs (branch 2025016)¶
Description¶
Profitable scenario: issued invoices exceed received invoices. Validates positive difference and issued-tab functionality with drawn proforma.
Preconditions¶
- Clean database (
TestControl.cleanDb()) - User logged in with ADMIN role
- Contract created via API with branch-specific mock data loaded from
receipts-branch-*.json - Contract price 800 000 Kč, branch 2025016
- Mock
receipts-branch-2025016_issued_heavy.json(1 received + 6 issued, including fully drawn 200 000 proforma)
Steps¶
- Open Received tab — Expected: 1 row FP2025116001 = 35 000 Kč
- Assert revenues = 615 000 Kč net — Expected: Includes drawn proforma adjustments
- Assert positive final difference — Expected: Profitable outcome
- Switch to Issued tab — Expected: 6 issued rows shown
Related¶
- Spec:
tests/e2e/tests/contracts.spec.ts
Media¶

