---
id: ATS-ACC-BKS-010
scope: CAP-ACC-BKS-010
product_area: accounting
module: books
revision: 2
status: proposed
approved_by: null
approved_at: null
source_sha:
  services-accounting: f47cb263875bbc0c5640fba7dae6785ec32695f8
  react-console: baf6dae382d6f41dce976c7f848667ccc37e076f
scenarios:
  - id: ATS-ACC-BKS-010-01
    title: Advance the current period through open work
    level: api
    proves:
      - BR-CAP-ACC-BKS-010-01
    preconditions: Two fiscal years begin fully open.
    steps: >-
      Read the current period as early periods, the first year and finally all
      periods close.
    expected: >-
      The answer advances to the earliest open period, then the next open year
      and finally no current period.
    negative: false
    data_needs: The setup needs no extra fixture records.
    bound_to:
      - TST-ACC-BKS-086
      - TST-ACC-BKS-054
    provenance: test
    source: >-
      services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#answers
      the first period of the earliest year with its whole year, when nothing is
      closed
    category: rule
    binding_evidence:
      - >-
        services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#answers
        the first period of the earliest year with its whole year, when nothing
        is closed
      - >-
        services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#moves
        on to the first open period once the earlier ones are closed
      - >-
        services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#moves
        on to the next year once the earliest is closed
      - >-
        services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
        404 in Rhythm 1.0’s words
  - id: ATS-ACC-BKS-010-02
    title: Find existing periods at their boundaries
    level: api
    proves:
      - BR-CAP-ACC-BKS-010-02
      - BR-CAP-ACC-BKS-010-03
      - INV-DOM-ACC-BKS-003-06
    preconditions: The unit has two generated years.
    steps: >-
      Look up beginning, interior and ending dates, a closed period and a date
      after coverage.
    expected: >-
      Existing dates select the right period; the uncovered date is not found
      and causes no generation.
    negative: false
    data_needs: The setup needs no extra fixture records.
    bound_to:
      - TST-ACC-BKS-054
      - TST-ACC-BKS-086
    provenance: test
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      404 to the day after the last year, generating nothing
    category: boundary
    binding_evidence:
      - >-
        services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
        404 to the day after the last year, generating nothing
      - >-
        services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#leaves
        the unit its two years after that lookup
      - >-
        services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#answers
        the year’s last period on the year’s last day, not the next year
      - >-
        services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#answers
        a closed period of a closed year
  - id: ATS-ACC-BKS-010-03
    title: Report and repair scheduled calendar gaps
    level: api
    proves:
      - BR-CAP-ACC-BKS-010-06
    preconditions: A recurring roll is dated beyond the final year.
    steps: 'Run it, generate the missing calendar and retry.'
    expected: >-
      The first failure identifies unit and date; the later roll records the
      covered year and period.
    negative: true
    data_needs: The setup needs no extra fixture records.
    bound_to:
      - TST-ACC-BKS-187
    provenance: test
    source: >-
      services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#fails
      the roll dated in no fiscal year of the unit, with the sentence naming the
      date and the unit
    category: failure
    binding_evidence:
      - >-
        services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#fails
        the roll dated in no fiscal year of the unit, with the sentence naming
        the date and the unit
      - >-
        services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#records
        the fiscal year and period containing the batch date in the plan of the
        roll once the year exists
  - id: ATS-ACC-BKS-010-04
    title: Exercise the grants for locate the fiscal period for accounting work
    category: permission
    level: api
    proves:
      - BR-CAP-ACC-BKS-016-01
      - BR-CAP-ACC-BKS-010-05
    preconditions: >-
      An application-authorized reader and administrator share the run-owned
      setup. A third principal lacks the relevant resource grant.
    steps: >-
      Read current and dated periods as the reader, then repeat without
      calendar-read access. Compare the stored calendar before and after.
    expected: >-
      Reader lookups succeed without changing coverage; the caller without
      calendar-read access is refused.
    negative: true
    data_needs: >-
      Run-owned records for the stated setup; retain the initial values for
      comparison.
    bound_to: []
    provenance: proposed
    source: >-
      services-accounting:modules/books/tests/e2e/configuration-security.e2e.spec.js#is
      refused the create 403 permission_missing
    permissions_exercised:
      - accounting.fiscal-years.read
    binding_evidence: []
    supporting_tests:
      - >-
        services-accounting:modules/books/tests/e2e/configuration-security.e2e.spec.js#reads
        the fiscal period for a date
  - id: ATS-ACC-BKS-010-05
    title: Coverage repair changes the next scheduled roll outcome
    category: interaction
    level: api
    proves:
      - BR-CAP-ACC-BKS-010-06
      - BR-CAP-ACC-BKS-018-07
    preconditions: >-
      Run-owned records satisfy the preconditions of the referenced capability
      proofs.
    steps: >-
      Run an occurrence outside coverage, extend coverage and run a later
      eligible occurrence.
    expected: >-
      The earlier run retains its failure and the later roll records its covered
      year and period.
    negative: false
    data_needs: >-
      Run-owned records for the stated setup; retain the initial values for
      comparison.
    bound_to:
      - TST-ACC-BKS-187
    provenance: test
    source:
      - >-
        services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#fails
        the roll dated in no fiscal year of the unit, with the sentence naming
        the date and the unit
      - >-
        services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#pauses
        the schedule after the fifth failure in a row
    exercises:
      - CAP-ACC-BKS-010
      - CAP-ACC-BKS-018
    workflows:
      - WF-ACC-BKS-008
    binding_evidence:
      - >-
        services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#fails
        the roll dated in no fiscal year of the unit, with the sentence naming
        the date and the unit
evidence:
  - >-
    Verified source file:
    services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js
  - >-
    Verified source file:
    services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js
  - >-
    Verified source file:
    services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js
product_intent: proposed
state_transition_coverage:
  - state_model: STATE-ACC-BKS-002
    from: ungenerated
    to: open
    trigger: Generate calendar coverage
    provenance: test
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      the two years asked for, each following the one before
    scenarios:
      - ATS-ACC-BKS-009-01
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: open
    to: closing
    trigger: Begin closing a period
    provenance: observed
    source: >-
      services-accounting:modules/fiscal-close/services/rules/transitions.ts:PERIOD_STATUS_TRANSITIONS
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: closing
    to: closed
    trigger: Finalize the close
    provenance: test
    source: >-
      services-accounting:modules/books/tests/integration/db/fiscal-years.table.integration.spec.js#closes
      the year when its last open period is closed
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: closing
    to: open
    trigger: Return a failed or cancelled close to open
    provenance: observed
    source: >-
      services-accounting:modules/fiscal-close/services/rules/transitions.ts:PERIOD_STATUS_TRANSITIONS
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: closed
    to: reopening
    trigger: Begin reopening
    provenance: observed
    source: >-
      services-accounting:modules/books/db/fiscal-periods.table.ts:fiscal_periods_year_status_trigger
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: reopening
    to: open
    trigger: Complete reopening
    provenance: observed
    source: >-
      services-accounting:modules/fiscal-close/services/persistence/fiscal-periods.ts
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: reopening
    to: closed
    trigger: Return a failed reopening to closed
    provenance: observed
    source: >-
      services-accounting:modules/fiscal-close/services/rules/transitions.ts:PERIOD_STATUS_TRANSITIONS
    scenarios: []
    gap: FND-ACC-BKS-071
    observation_only: true
  - state_model: STATE-ACC-BKS-002
    from: open
    to: removed
    trigger: Remove eligible calendar records
    provenance: test
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      409 naming the latest year
    scenarios:
      - ATS-ACC-BKS-009-06
    observation_only: true
coverage:
  rule: covered
  transition: not-applicable
  validation: 'gap: FND-ACC-BKS-071'
  permission: covered
  edge: 'gap: FND-ACC-BKS-071'
  failure: covered
  boundary: covered
  concurrency: 'gap: FND-ACC-BKS-071'
  invariant: 'gap: FND-ACC-BKS-071'
  interaction: covered
coverage_notes:
  rule:
    scenarios:
      - ATS-ACC-BKS-010-01
    provenance: documented
    source:
      - ATS-ACC-BKS-010-01
  transition:
    reason: >-
      This capability initiates no independent state-model transition; its edits
      or reads use the owning record lifecycle and related-capability scenarios.
    provenance: documented
    source: >-
      specs/accounting/books/planning/capabilities/CAP-ACC-BKS-010-find-the-fiscal-period-a-date-or-today-falls-in.md
  validation:
    scenarios: []
    provenance: unknown
    source: FND-ACC-BKS-071
    reason: >-
      No scenario isolates this category for the capability at the pinned
      revision.
    gap: FND-ACC-BKS-071
  permission:
    scenarios:
      - ATS-ACC-BKS-010-04
    provenance: documented
    source:
      - ATS-ACC-BKS-010-04
  edge:
    scenarios: []
    provenance: unknown
    source: FND-ACC-BKS-071
    reason: >-
      No scenario isolates this category for the capability at the pinned
      revision.
    gap: FND-ACC-BKS-071
  failure:
    scenarios:
      - ATS-ACC-BKS-010-03
    provenance: documented
    source:
      - ATS-ACC-BKS-010-03
  boundary:
    scenarios:
      - ATS-ACC-BKS-010-02
    provenance: documented
    source:
      - ATS-ACC-BKS-010-02
  concurrency:
    scenarios: []
    provenance: unknown
    source: FND-ACC-BKS-071
    reason: >-
      No scenario isolates this category for the capability at the pinned
      revision.
    gap: FND-ACC-BKS-071
  invariant:
    scenarios: []
    provenance: unknown
    source: FND-ACC-BKS-071
    reason: >-
      No scenario isolates this category for the capability at the pinned
      revision.
    gap: FND-ACC-BKS-071
  interaction:
    scenarios:
      - ATS-ACC-BKS-010-05
    provenance: documented
    source:
      - ATS-ACC-BKS-010-05
rule_coverage:
  - rule: BR-CAP-ACC-BKS-010-01
    scenarios:
      - ATS-ACC-BKS-010-01
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#moves
      on to the first open period once the earlier ones are closed
  - rule: BR-CAP-ACC-BKS-010-02
    scenarios:
      - ATS-ACC-BKS-010-02
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      404 to the day after the last year, generating nothing
  - rule: BR-CAP-ACC-BKS-010-03
    scenarios:
      - ATS-ACC-BKS-010-02
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/integration/services/persistence/fiscal-periods.queries.integration.spec.js#answers
      the year’s last period on the year’s last day, not the next year
  - rule: BR-CAP-ACC-BKS-010-06
    scenarios:
      - ATS-ACC-BKS-010-03
      - ATS-ACC-BKS-010-05
    provenance: documented
    source: >-
      services-accounting:modules/maintenance/tests/integration/services/scheduling/schedules-end-to-end.integration.spec.js#fails
      the roll dated in no fiscal year of the unit, with the sentence naming the
      date and the unit
related_coverage:
  - capability: CAP-ACC-BKS-018
    scenarios:
      - ATS-ACC-BKS-010-05
    provenance: documented
    source: >-
      specs/accounting/books/planning/capabilities/CAP-ACC-BKS-010-find-the-fiscal-period-a-date-or-today-falls-in.md
workflow_coverage:
  - workflow: WF-ACC-BKS-005
    interactions: []
    provenance: documented
    source: >-
      specs/accounting/books/design/workflows/WF-ACC-BKS-005-generate-a-units-next-fiscal-years.md
    gap: FND-ACC-BKS-071
  - workflow: WF-ACC-BKS-008
    interactions:
      - ATS-ACC-BKS-010-05
    provenance: documented
    source: >-
      specs/accounting/books/design/workflows/WF-ACC-BKS-008-dispatch-and-run-scheduled-accounting-work.md
    gap: FND-ACC-BKS-071
coverage_interpretation: >-
  Covered means a specified scenario exists. Proposed scenarios and registered
  bindings do not establish a passed run or verified conformance.
invariant_coverage:
  - invariant: INV-DOM-ACC-BKS-003-01
    scenarios:
      - ATS-ACC-BKS-009-04
      - ATS-ACC-BKS-009-11
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/integration/db/fiscal-years.table.integration.spec.js#refuses
      a year leaving a gap after the latest, in Rhythm 1.0’s sentence
  - invariant: INV-DOM-ACC-BKS-003-02
    scenarios:
      - ATS-ACC-BKS-009-07
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/integration/db/fiscal-years.table.integration.spec.js#closes
      the year when its last open period is closed
  - invariant: INV-DOM-ACC-BKS-003-03
    scenarios:
      - ATS-ACC-BKS-009-05
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      409 to a changed start date, naming the column
  - invariant: INV-DOM-ACC-BKS-003-04
    scenarios:
      - ATS-ACC-BKS-009-06
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      409 naming the latest year
  - invariant: INV-DOM-ACC-BKS-003-05
    scenarios:
      - ATS-ACC-BKS-009-03
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/integration/services/persistence/fiscal-years.integration.spec.js#writes
      none of the years, not even the years within reach
  - invariant: INV-DOM-ACC-BKS-003-06
    scenarios:
      - ATS-ACC-BKS-010-02
    provenance: documented
    source: >-
      services-accounting:modules/books/tests/e2e/fiscal-years.e2e.spec.js#answers
      404 to the day after the last year, generating nothing
permission_coverage:
  - key: accounting.fiscal-years.read
    where_checked: api
    scenarios:
      - ATS-ACC-BKS-010-04
    provenance: documented
    source: >-
      specs/accounting/books/planning/capabilities/CAP-ACC-BKS-010-find-the-fiscal-period-a-date-or-today-falls-in.md
    execution_gap: FND-ACC-BKS-071
reviewed_at: '2026-10-23'
---

# Locate the fiscal period for accounting work: Capability Test Specification

## Coverage

- Advance the current period through open work.
- Find existing periods at their boundaries.
- Find existing periods at their boundaries.
- Report and repair scheduled calendar gaps.

The structured coverage map distinguishes specified examples from remaining findings. Proposed examples require executable proof before qualification.

## Interactions With Related Capabilities

- Coverage repair changes the next scheduled roll outcome.

Related-capability and workflow references identify the seams each scenario exercises. The lifecycle coverage record retains transitions that still need individual proof.

## Binding Review

The pinned service and browser assertions support the registered bindings. Original test references remain beside each scenario so partial evidence and unresolved conformance remain reviewable.
