{
  "format": "vercy-enterprise-allocation-fixtures/v1",
  "candidateName": "Chart of Accounts / Accounting Policy",
  "cases": [
    {
      "id": "statutory-management-divergence",
      "kind": "positive",
      "covers": [
        "I07",
        "I08",
        "I09",
        "I27"
      ],
      "input": "One settlement produces a statutory EUR entry and management USD entry with different accounts and recognition dates.",
      "expect": "Both entries balance independently, share only pinned event correlation and record basis, FX and classification divergence."
    },
    {
      "id": "hard-close-restricted-cash-correction",
      "kind": "positive",
      "covers": [
        "I05",
        "I10",
        "I11",
        "I12",
        "I13"
      ],
      "input": "After the statutory ledger hard-closes, Cash-GL must be reclassified to Restricted-Cash while management is correct.",
      "expect": "A linked statutory correction posts in the earliest open permitted later period or as an appended linked entry under an explicit authorityRef exception; original entry and every emitted balance remain immutable; management is unchanged."
    },
    {
      "id": "open-period-correction",
      "kind": "positive",
      "covers": [
        "I10",
        "P04"
      ],
      "input": "A posting error is found while the ledger period remains open.",
      "expect": "A linked reversal or adjustment is appended in the same ledger; original lines are unchanged."
    },
    {
      "id": "chart-successor",
      "kind": "positive",
      "covers": [
        "I19",
        "I20",
        "I28"
      ],
      "input": "Account hierarchy is reorganised for the next fiscal year.",
      "expect": "A successor Chart revision and effective Ledger Accounts preserve predecessor paths and historical interpretation."
    },
    {
      "id": "optional-financial-backing",
      "kind": "positive",
      "covers": [
        "I06",
        "P11"
      ],
      "input": "A statutory cash Ledger Account maps to one bank Financial Account for a declared entity and interval.",
      "expect": "Mapping is stored as context-qualified correspondence and does not merge identities."
    },
    {
      "id": "global-account-code",
      "kind": "negative",
      "covers": [
        "I04",
        "I17"
      ],
      "input": "Code 4000 is treated as globally identical across statutory and management ledgers.",
      "expect": "Rejected because Ledger Account identity is ledger-, Chart-revision- and interval-scoped."
    },
    {
      "id": "raw-financial-account-posting",
      "kind": "negative",
      "covers": [
        "I18"
      ],
      "input": "A Posting targets a WM-ECO-015 bank account directly.",
      "expect": "Rejected; Posting must target a Ledger Account governed by the effective Chart revision."
    },
    {
      "id": "cross-ledger-balance",
      "kind": "negative",
      "covers": [
        "I07",
        "I08",
        "P09"
      ],
      "input": "A statutory debit offsets a management credit to satisfy balancing.",
      "expect": "Rejected because no balancing scope spans ledgers."
    },
    {
      "id": "cross-ledger-tolerance-plug",
      "kind": "negative",
      "covers": [
        "I08",
        "I23",
        "I24"
      ],
      "input": "A statutory residual is plugged into a management entry.",
      "expect": "Rejected; residuals post inside the same ledger under its pinned policy."
    },
    {
      "id": "event-as-entry-identity",
      "kind": "negative",
      "covers": [
        "I15"
      ],
      "input": "The external settlement identifier is reused as the Journal Entry identity in two ledgers.",
      "expect": "Rejected; correlation never replaces ledger-local entry identity."
    },
    {
      "id": "policy-rewrites-entry",
      "kind": "negative",
      "covers": [
        "I10",
        "I19"
      ],
      "input": "A successor accounting policy rewrites prior posted lines.",
      "expect": "Rejected; the new policy is effective-dated and history changes only through linked corrections or restatement."
    },
    {
      "id": "hard-close-silent-reopen",
      "kind": "negative",
      "covers": [
        "I11"
      ],
      "input": "A closed statutory period is silently reopened and the original entry edited.",
      "expect": "Rejected; explicit exception or later-period correction is required."
    },
    {
      "id": "sibling-auto-correction",
      "kind": "negative",
      "covers": [
        "I12",
        "P12"
      ],
      "input": "Correcting the statutory sibling automatically changes management.",
      "expect": "Rejected; correction authority and timing are per ledger."
    },
    {
      "id": "closed-balance-mutation",
      "kind": "negative",
      "covers": [
        "I13"
      ],
      "input": "A correction overwrites the closed-period WM-ECO-017 balance.",
      "expect": "Rejected; closed balance is immutable and later assertions carry new as-of context."
    },
    {
      "id": "treasury-gl-fusion",
      "kind": "negative",
      "covers": [
        "I01",
        "I14"
      ],
      "input": "Bank position and GL balance are stored as one authoritative object.",
      "expect": "Rejected; treasury/custody position and per-ledger GL balance remain distinct."
    },
    {
      "id": "profile-mints-ledger-account",
      "kind": "negative",
      "covers": [
        "P01",
        "P03"
      ],
      "input": "The Enterprise profile creates a Ledger Account key.",
      "expect": "Rejected as stealth mastership."
    },
    {
      "id": "cascade-delete",
      "kind": "negative",
      "covers": [
        "P13"
      ],
      "input": "Deleting a correspondence removes a source entry or account.",
      "expect": "Rejected; profile bindings never cascade-delete masters."
    },
    {
      "id": "ledger-adoption-exclusivity",
      "kind": "negative",
      "covers": [
        "I21"
      ],
      "input": "One ledger has overlapping effective adoptions of two Charts.",
      "expect": "Rejected; one Chart adoption per ledger instant."
    },
    {
      "id": "adoption-revocation-retroactive",
      "kind": "negative",
      "covers": [
        "I21"
      ],
      "input": "Adoption closure predates an already-posted entry.",
      "expect": "Rejected; supersession is prospective and preserves posted pins."
    },
    {
      "id": "policy-pinning-conflict",
      "kind": "negative",
      "covers": [
        "I22"
      ],
      "input": "Ledger Account narrows to a policy lineage different from effective adoption.",
      "expect": "Rejected; narrowing must remain in adopted lineage and adoption governs."
    },
    {
      "id": "ledger-account-identity-continuity",
      "kind": "positive",
      "covers": [
        "I28"
      ],
      "input": "Unchanged node continues across a successor Chart revision.",
      "expect": "Stable ledgerAccountId and balance series continue; predecessorRef resolves."
    },
    {
      "id": "overlapping-account-intervals",
      "kind": "negative",
      "covers": [
        "I17"
      ],
      "input": "Two Ledger Account versions for one ledger and node overlap.",
      "expect": "Rejected."
    },
    {
      "id": "duplicate-account-code-in-ledger",
      "kind": "negative",
      "covers": [
        "I17"
      ],
      "input": "Two accounts share a code simultaneously in one ledger.",
      "expect": "Rejected."
    },
    {
      "id": "second-concurrent-backing",
      "kind": "negative",
      "covers": [
        "I06",
        "P11"
      ],
      "input": "A second backing account overlaps for the same context.",
      "expect": "Rejected; at most one effective backing per context."
    },
    {
      "id": "suspended-policy-posting",
      "kind": "negative",
      "covers": [
        "I19"
      ],
      "input": "New posting uses a suspended revision while a pre-suspension entry is reread.",
      "expect": "New posting rejected; prior pin remains valid and unchanged."
    },
    {
      "id": "retire-adopted-chart",
      "kind": "negative",
      "covers": [
        "I20"
      ],
      "input": "Chart is retired while adoption remains effective.",
      "expect": "Rejected absent no effective adoption or successor adoption."
    },
    {
      "id": "tolerance-residual-unposted",
      "kind": "negative",
      "covers": [
        "I23",
        "I24"
      ],
      "input": "Within-threshold residual is left unposted.",
      "expect": "Rejected; residual posts to designated same-ledger account and total is exactly zero."
    },
    {
      "id": "balancing-scope-undeclared",
      "kind": "negative",
      "covers": [
        "I07",
        "I14"
      ],
      "input": "Balancing uses an undeclared scope dimension.",
      "expect": "Rejected."
    },
    {
      "id": "fx-rate-restatement",
      "kind": "negative",
      "covers": [
        "I25"
      ],
      "input": "Rate revision recomputes prior translated posting in place.",
      "expect": "Rejected; linked same-ledger correction required."
    },
    {
      "id": "balance-currency-role-missing",
      "kind": "negative",
      "covers": [
        "I09"
      ],
      "input": "Balance is keyed by currency without currencyRole.",
      "expect": "Rejected."
    },
    {
      "id": "open-period-balance-overwrite",
      "kind": "negative",
      "covers": [
        "I13"
      ],
      "input": "Open-period balance assertion is overwritten.",
      "expect": "Rejected; successor assertion with own as-of and basis is emitted."
    },
    {
      "id": "late-entry-into-closed-period",
      "kind": "negative",
      "covers": [
        "I05",
        "I11"
      ],
      "input": "Entry with accountingDate in hard-closed period is recorded without exception.",
      "expect": "Rejected; use earliest open permitted later period or explicit authorityRef exception."
    },
    {
      "id": "late-entry-authorised-exception",
      "kind": "positive",
      "covers": [
        "I05",
        "I11"
      ],
      "input": "Late entry is appended under explicit authorityRef exception.",
      "expect": "Entry is linked and appended; original entry and emitted balances remain immutable."
    },
    {
      "id": "hard-close-exception-amends-original",
      "kind": "negative",
      "covers": [
        "I11"
      ],
      "input": "Authorised exception edits original closed entry.",
      "expect": "Rejected; exception permits append only."
    },
    {
      "id": "sibling-divergence-unstated",
      "kind": "negative",
      "covers": [
        "I08",
        "I27",
        "P08"
      ],
      "input": "Sibling sets differ in date and account without reason code.",
      "expect": "Rejected; closed-vocabulary reason and both policy pins required."
    },
    {
      "id": "multi-entry-single-event",
      "kind": "positive",
      "covers": [
        "I15",
        "I27"
      ],
      "input": "One event correlates to two entries in one ledger and one in another.",
      "expect": "Grouped by eventRef and ledgerRef; each entry balances alone; divergence is set-level."
    },
    {
      "id": "close-state-single-source",
      "kind": "negative",
      "covers": [
        "I26"
      ],
      "input": "Close state is asserted outside LedgerPeriod.",
      "expect": "Rejected; LedgerPeriod is the sole close-state master."
    },
    {
      "id": "binding-supersession",
      "kind": "positive",
      "covers": [
        "P07",
        "P14"
      ],
      "input": "A correspondence binding is superseded.",
      "expect": "Prior binding remains profile-resolvable; local key is non-subject; no source master changes."
    }
  ]
}
