---
id: ATS-ACC-BAT-004
scope: CAP-ACC-BAT-004
product_area: accounting
module: batches
revision: 2
status: proposed
source_sha:
  services-accounting: f47cb263875bbc0c5640fba7dae6785ec32695f8
  react-console: baf6dae382d6f41dce976c7f848667ccc37e076f
  rhythm-v2-docs: 37405d50d1465ea0571a66095d98ebec4db04175
scenarios:
  - id: ATS-ACC-BAT-004-01
    title: Transitions return the resulting state
    level: browser
    proves:
      - BR-CAP-ACC-BAT-004-01
      - BR-CAP-ACC-BAT-004-02
    preconditions: The selected batch starts Open.
    steps: 'Close, reopen and close it, then request Close again.'
    expected: Successful responses show the new state; closing twice returns 409.
    negative: true
    data_needs: Provide no fixtures beyond the stated setup.
    bound_to:
      - TST-ACC-BAT-055
      - TST-ACC-BAT-060
      - TST-ACC-BAT-085
      - TST-ACC-BAT-002
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#answers
      each status action with the updated batch
    category: transition
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#answers
        each status action with the updated batch
      - >-
        services-accounting:modules/batches/tests/e2e/batches.e2e.spec.js#closes
        it, then reopens it
      - >-
        services-accounting:modules/batches/tests/e2e/batches.e2e.spec.js#refuses
        closing it again 409
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
        closing a batch that is not open
      - >-
        react-console:acceptance/accounting/playwright/journeys/batches-posting/ACT-ACC-0502.spec.ts#ACT-ACC-0502
  - id: ATS-ACC-BAT-004-02
    title: Reopen clears posting errors
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-03
    preconditions: 'The selected records are Error, Open and Archived.'
    steps: Request Reopen on each.
    expected: >-
      Error becomes Open without errors; Open fails and Archived directs the
      user to unarchive.
    negative: true
    data_needs: Provide an errored batch from a failed posting.
    bound_to:
      - TST-ACC-BAT-085
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#clears
      the errors of an errored batch on reopen, so the open batch carries none
      (journey ACT-ACC-0521)
    category: transition
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#clears
        the errors of an errored batch on reopen, so the open batch carries none
        (journey ACT-ACC-0521)
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
        reopening a batch that is open
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
        reopening an archived batch: it is unarchived instead
  - id: ATS-ACC-BAT-004-03
    title: Archiving removes automatic close
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-04
      - BR-CAP-ACC-BAT-004-05
    preconditions: An Open batch has a close schedule; Closed and Posted batches also exist.
    steps: 'Archive each, unarchive eligible records and try unarchiving Open.'
    expected: >-
      Open and Closed archive without their schedules; Posted fails; unarchive
      returns Open and refuses an already-open record.
    negative: true
    data_needs: Provide no fixtures beyond the stated setup.
    bound_to:
      - TST-ACC-BAT-085
      - TST-ACC-BAT-055
      - TST-ACC-BAT-002
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
    category: interaction
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
        an open batch and a closed one, and unarchives to open
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
        archiving a posted batch 409
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#drops
        an archived batch’s automatic close, as an automatic close is kept only
        on an open batch
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
        unarchiving an open batch 409
      - >-
        react-console:acceptance/accounting/playwright/journeys/batches-posting/ACT-ACC-0502.spec.ts#ACT-ACC-0502
  - id: ATS-ACC-BAT-004-04
    title: Available actions reflect status
    level: unit
    proves:
      - BR-CAP-ACC-BAT-004-06
    preconditions: >-
      Every batch status is represented and the caller holds all action
      permissions.
    steps: Retrieve each action list.
    expected: The list agrees with the declared transition table.
    negative: false
    data_needs: Provide no fixtures beyond the stated setup.
    bound_to:
      - TST-ACC-BAT-119
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
      an open batch post, close and archive
    category: rule
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        an open batch post, close and archive
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        a closed batch post, reopen and archive
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        a verified batch reopen only
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        an errored batch post again and reopen
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        an archived batch unarchive only
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        a posted or downloaded batch unpost only
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        a batch posting for half an hour nothing, and one stuck in posting for
        over an hour unpost
  - id: ATS-ACC-BAT-004-05
    title: Each transition checks its permission
    level: browser
    proves:
      - BR-CAP-ACC-BAT-004-07
    preconditions: >-
      Reader, staff and administrator personas can inspect Open and Posted
      batches.
    steps: Inspect and invoke each available transition.
    expected: >-
      Readers receive no actions; staff receive ordinary actions without Unpost;
      administrators receive the recovery actions; denied calls return 403.
    negative: true
    data_needs: Provide the acceptance personas.
    bound_to:
      - TST-ACC-BAT-119
      - TST-ACC-BAT-055
      - TST-ACC-BAT-027
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#refuses
      a caller without the action’s permission, 403, before the command runs
    category: permission
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#refuses
        a caller without the action’s permission, 403, before the command runs
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
        a caller who may update but not post the status actions alone
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#lists
        a read-only caller no action
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
        a read-only caller 403, and the batch stays open
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
        archiving to a caller without accounting.batches.update 403
      - >-
        react-console:acceptance/accounting/playwright/journeys/batches-posting/ACT-ACC-0540.spec.ts#ACT-ACC-0540
  - id: ATS-ACC-BAT-004-06
    title: Locks disable transitions
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-08
    preconditions: The batch has an update lock.
    steps: Retrieve its actions and request Archive.
    expected: >-
      The disabled ordinary actions identify the lock and Archive returns a
      locked-record refusal.
    negative: true
    data_needs: Provide no fixtures beyond the stated setup.
    bound_to:
      - TST-ACC-BAT-119
      - TST-ACC-BAT-085
      - TST-ACC-BAT-003
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#lists
      a locked batch’s status actions with the refusal the command would answer
      as disabled_reason
    category: invariant
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#lists
        a locked batch’s status actions with the refusal the command would
        answer as disabled_reason
      - >-
        services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
        archiving a batch locked against updates 409
      - >-
        react-console:acceptance/accounting/playwright/journeys/batches-posting/ACT-ACC-0503.spec.ts#ACT-ACC-0503
  - id: ATS-ACC-BAT-004-07
    title: System batches reject staff transitions
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-09
    preconditions: A fiscal close has created a deferred-revenue batch.
    steps: 'As an administrator, retrieve and invoke its actions.'
    expected: >-
      The list is empty; attempted actions return a system-batch 409 without
      changing the record.
    negative: true
    data_needs: Provide a fiscal close's system batch.
    bound_to:
      - TST-ACC-BAT-063
      - TST-ACC-BAT-074
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#offers
      an administrator no action for the system batch
    category: edge
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#offers
        an administrator no action for the system batch
      - >-
        services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#refuses
        the action close 409 system_batch
      - >-
        services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#leaves
        the batch unchanged after every refused action
      - >-
        services-accounting:modules/batches/tests/integration/services/close/system-batch-guard.integration.spec.js#refuses
        it in every action’s guard, with the system batch refusal
  - id: ATS-ACC-BAT-004-08
    title: Actions reject unsupported requests
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-11
    preconditions: The batch is Open.
    steps: >-
      Invoke an unavailable action and submit Close with another batch reference
      in its body.
    expected: >-
      Both requests return 400; the unsupported-action error identifies the
      choices.
    negative: true
    data_needs: Provide no fixtures beyond the stated setup.
    bound_to:
      - TST-ACC-BAT-055
    provenance: test
    source: >-
      services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
      an action the batch has not 400, naming the actions
    category: validation
    test_evidence:
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
        an action the batch has not 400, naming the actions
      - >-
        services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
        a batch_id, which no batch action takes, 400
  - id: ATS-ACC-BAT-004-09
    title: Archive protection ends through Unarchive
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-003-03
      - BR-CAP-ACC-BAT-004-05
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-003
    workflows:
      - WF-ACC-BAT-001
    preconditions: Morning starts Open with description First.
    steps: >-
      Archive Morning, try to change its description, unarchive it and save
      Second.
    expected: >-
      The archived save returns 409; the final read is Open with description
      Second.
    negative: true
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/services/persistence/batches.ts:changeBatch;
      services-accounting:modules/batches/services/rules/batch-rules.ts:assertBatchChangesAllowed;
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
  - id: ATS-ACC-BAT-004-10
    title: Manual close cancels a scheduled close
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-02
      - BR-CAP-ACC-BAT-005-05
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-005
    workflows:
      - WF-ACC-BAT-001
    preconditions: Morning is Open with a future close occurrence.
    steps: Close it manually and deliver the old occurrence after it is due.
    expected: Morning remains Closed and the old delivery cannot close it again.
    negative: false
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
      closing a batch that is not open;
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#removes
      the schedule and the time when the batch is closed
  - id: ATS-ACC-BAT-004-11
    title: Reopening retires one attention generation
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-03
      - BR-CAP-ACC-BAT-008-04
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-008
    workflows:
      - WF-ACC-BAT-001
    preconditions: Attention publication is enabled and Morning is Open.
    steps: 'Close Morning, inspect its attention, reopen it, then close it again.'
    expected: The first item is resolved and the second close creates a new generation.
    negative: false
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#clears
      the errors of an errored batch on reopen, so the open batch carries none
      (journey ACT-ACC-0521);
      services-accounting:modules/batches/tests/integration/services/persistence/batch-attention-items.integration.spec.js#resolves
      a reopened batch reopened, and its next close opens the second generation
  - id: ATS-ACC-BAT-004-12
    title: Post produces a protected completed batch
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-01
      - BR-CAP-ACC-BAT-013-03
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-013
    workflows:
      - WF-ACC-BAT-005
    preconditions: Morning is Open with one eligible invoice.
    steps: 'Post through the named action, wait for completion and attempt Archive.'
    expected: >-
      Morning becomes Posted with an entry; Archive returns 409 and preserves
      it.
    negative: true
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#answers
      each status action with the updated batch;
      services-accounting:modules/batches/tests/e2e/batch-postings.e2e.spec.js#posts
      a batch as a durable job: the answer is the job, and the job posts the
      batch
  - id: ATS-ACC-BAT-004-13
    title: Unpost restores ordinary actions
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-06
      - BR-CAP-ACC-BAT-016-06
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-016
    workflows:
      - WF-ACC-BAT-006
    preconditions: Morning is Posted in an Open period.
    steps: >-
      Unpost through the named action and retrieve the resulting action
      catalogue.
    expected: Morning is Open and offers Close and Archive again.
    negative: false
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
      a batch posting for half an hour nothing, and one stuck in posting for
      over an hour unpost;
      services-accounting:modules/batches/tests/e2e/batch-postings.e2e.spec.js#unposts
      a posted batch as a durable job: the batch is open again and its entries
      are deleted
  - id: ATS-ACC-BAT-004-14
    title: Fiscal collections reject ordinary controls
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-09
      - BR-CAP-ACC-BAT-020-11
    exercises:
      - CAP-ACC-BAT-004
      - CAP-ACC-BAT-020
    workflows: []
    preconditions: Fiscal close has produced a Posted deferred-revenue system batch.
    steps: 'Retrieve its ordinary actions and attempt Close, Archive and Unpost.'
    expected: >-
      The action list is empty and each attempted ordinary action is refused
      without changing fiscal entries.
    negative: true
    data_needs: >-
      An isolated workspace with the stated business-unit calendar, documents
      and configuration.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#offers
      an administrator no action for the system batch;
      react-console:acceptance/accounting/playwright/journeys/batches-posting/ACT-ACC-0528.spec.ts#ACT-ACC-0528
  - id: ATS-ACC-BAT-004-15
    title: Stuck-posting actions respect the one-hour boundary
    category: boundary
    level: api
    proves:
      - BR-CAP-ACC-BAT-004-06
    preconditions: >-
      Two Posting batches last changed exactly one hour ago and one hour plus
      one second ago.
    steps: Retrieve their permitted actions at a fixed clock.
    expected: Only the older batch offers Unpost.
    negative: true
    data_needs: >-
      Owned records in an isolated workspace with the stated calendar and
      accounting setup.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
      a batch posting for half an hour nothing, and one stuck in posting for
      over an hour unpost
evidence:
  - services-accounting at f47cb263: 'Inspected references: scenario-bound tests in modules/batches/tests.'
  - react-console at baf6dae3: >-
      Inspected references:
      acceptance/accounting/playwright/journeys/batches-posting (ACT-ACC-0502,
      0503, 0540).
  - >-
    Pinned design objects, state models and workflows identify invariant and
    interaction obligations; scenario test anchors remain in test_evidence.
product_intent: proposed
coverage:
  rule: covered
  transition: 'gap: FND-ACC-BAT-058'
  validation: covered
  permission: 'gap: FND-ACC-BAT-058'
  edge: covered
  failure: 'gap: FND-ACC-BAT-058'
  boundary: covered
  concurrency: 'gap: FND-ACC-BAT-058'
  invariant: covered
  interaction: covered
coverage_notes:
  failure: >-
    Exact stuck-posting thresholds, concurrent actions, read-permission refusal,
    confirmation cancellation and failure during schedule or attention cleanup
    need focused proof.
  boundary: >-
    Exact stuck-posting thresholds, concurrent actions, read-permission refusal,
    confirmation cancellation and failure during schedule or attention cleanup
    need focused proof.
  concurrency: >-
    Exact stuck-posting thresholds, concurrent actions, read-permission refusal,
    confirmation cancellation and failure during schedule or attention cleanup
    need focused proof.
rule_coverage:
  - rule: BR-CAP-ACC-BAT-004-01
    scenarios:
      - ATS-ACC-BAT-004-01
      - ATS-ACC-BAT-004-12
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#answers
      each status action with the updated batch
  - rule: BR-CAP-ACC-BAT-004-02
    scenarios:
      - ATS-ACC-BAT-004-01
      - ATS-ACC-BAT-004-10
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
      closing a batch that is not open
  - rule: BR-CAP-ACC-BAT-004-03
    scenarios:
      - ATS-ACC-BAT-004-02
      - ATS-ACC-BAT-004-11
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#clears
      the errors of an errored batch on reopen, so the open batch carries none
      (journey ACT-ACC-0521)
  - rule: BR-CAP-ACC-BAT-004-04
    scenarios:
      - ATS-ACC-BAT-004-03
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#refuses
      archiving a posted batch 409
  - rule: BR-CAP-ACC-BAT-004-05
    scenarios:
      - ATS-ACC-BAT-004-03
      - ATS-ACC-BAT-004-09
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
  - rule: BR-CAP-ACC-BAT-004-06
    scenarios:
      - ATS-ACC-BAT-004-04
      - ATS-ACC-BAT-004-13
      - ATS-ACC-BAT-004-15
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#offers
      a batch posting for half an hour nothing, and one stuck in posting for
      over an hour unpost
  - rule: BR-CAP-ACC-BAT-004-07
    scenarios:
      - ATS-ACC-BAT-004-05
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#refuses
      a caller without the action’s permission, 403, before the command runs
  - rule: BR-CAP-ACC-BAT-004-08
    scenarios:
      - ATS-ACC-BAT-004-06
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/unit/actions/batch-actions.spec.js#lists
      a locked batch’s status actions with the refusal the command would answer
      as disabled_reason
  - rule: BR-CAP-ACC-BAT-004-09
    scenarios:
      - ATS-ACC-BAT-004-07
      - ATS-ACC-BAT-004-14
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/e2e/system-batches.e2e.spec.js#offers
      an administrator no action for the system batch
  - rule: BR-CAP-ACC-BAT-004-11
    scenarios:
      - ATS-ACC-BAT-004-08
    provenance: proposed
    source: >-
      services-accounting:modules/batches/tests/e2e/batch-actions.e2e.spec.js#refuses
      an action the batch has not 400, naming the actions
transition_coverage:
  - state_model: STATE-ACC-BAT-001
    transition: 1
    from: open
    to: closed
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#removes
      the schedule and the time when the batch is closed
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 12
    from: closed
    to: open
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batch-attention-items.integration.spec.js#resolves
      a reopened batch reopened, and its next close opens the second generation
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 13
    from: verified
    to: open
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/services/rules/batch-rules.ts:BATCH_REOPENABLE_STATUSES
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 14
    from: error
    to: open
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#clears
      the errors of an errored batch on reopen, so the open batch carries none
      (journey ACT-ACC-0521)
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 15
    from: open
    to: archived
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 16
    from: closed
    to: archived
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
  - state_model: STATE-ACC-BAT-001
    transition: 17
    from: archived
    to: open
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: >-
      services-accounting:modules/batches/tests/integration/services/persistence/batches.integration.spec.js#archives
      an open batch and a closed one, and unarchives to open
    note: >-
      The existing scenario set is not an exhaustive proof of this transition
      and all its side effects.
permission_coverage:
  - key: accounting.batches.read
    surface: api
    scenarios:
      - ATS-ACC-BAT-004-05
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: FND-ACC-BAT-058
    note: >-
      An aggregate persona check does not establish exhaustive allow and deny
      proof for every named surface.
  - key: accounting.batches.update
    surface: api
    scenarios:
      - ATS-ACC-BAT-004-05
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: FND-ACC-BAT-058
    note: >-
      An aggregate persona check does not establish exhaustive allow and deny
      proof for every named surface.
  - key: accounting.batch-postings.post
    surface: api
    scenarios:
      - ATS-ACC-BAT-004-05
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: FND-ACC-BAT-058
    note: >-
      An aggregate persona check does not establish exhaustive allow and deny
      proof for every named surface.
  - key: accounting.batch-postings.unpost
    surface: api
    scenarios:
      - ATS-ACC-BAT-004-05
    gap: FND-ACC-BAT-058
    provenance: unknown
    source: FND-ACC-BAT-058
    note: >-
      An aggregate persona check does not establish exhaustive allow and deny
      proof for every named surface.
executable_coverage:
  bound_scenarios: 8
  unbound_scenarios:
    - ATS-ACC-BAT-004-09
    - ATS-ACC-BAT-004-10
    - ATS-ACC-BAT-004-11
    - ATS-ACC-BAT-004-12
    - ATS-ACC-BAT-004-13
    - ATS-ACC-BAT-004-14
    - ATS-ACC-BAT-004-15
  gap: FND-ACC-BAT-058
---

# Use the batch’s permitted lifecycle actions: Capability Test Specification

## Coverage

The scenarios define focused checks for this outcome. The coverage map distinguishes specified checks from unresolved proof; executable bindings identify inspected assertions and carry no execution result.

| Rule | Proof Specification or Gap |
|---|---|
| `BR-CAP-ACC-BAT-004-01` | `ATS-ACC-BAT-004-01`, `ATS-ACC-BAT-004-12` |
| `BR-CAP-ACC-BAT-004-02` | `ATS-ACC-BAT-004-01`, `ATS-ACC-BAT-004-10` |
| `BR-CAP-ACC-BAT-004-03` | `ATS-ACC-BAT-004-02`, `ATS-ACC-BAT-004-11` |
| `BR-CAP-ACC-BAT-004-04` | `ATS-ACC-BAT-004-03` |
| `BR-CAP-ACC-BAT-004-05` | `ATS-ACC-BAT-004-03`, `ATS-ACC-BAT-004-09` |
| `BR-CAP-ACC-BAT-004-06` | `ATS-ACC-BAT-004-04`, `ATS-ACC-BAT-004-13`, `ATS-ACC-BAT-004-15` |
| `BR-CAP-ACC-BAT-004-07` | `ATS-ACC-BAT-004-05` |
| `BR-CAP-ACC-BAT-004-08` | `ATS-ACC-BAT-004-06` |
| `BR-CAP-ACC-BAT-004-09` | `ATS-ACC-BAT-004-07`, `ATS-ACC-BAT-004-14` |
| `BR-CAP-ACC-BAT-004-11` | `ATS-ACC-BAT-004-08` |

## Interactions With Related Capabilities

Archive protection ends through Unarchive. Manual close cancels a scheduled close. Reopening retires one attention generation. Post produces a protected completed batch. Unpost restores ordinary actions. Fiscal collections reject ordinary controls. These checks use the related capability’s outcome as part of the setup or verification. Unbound interactions remain proposed until a suite executes the complete chain.
