---
id: TST-ACC-TRX-024
title: Payment methods backfill suite
kind: integration
product_area: accounting
module: transactions
revision: 1
status: draft
source_sha:
  services-accounting: f47cb263875bbc0c5640fba7dae6785ec32695f8
repository: services-accounting
files:
  - >-
    modules/transactions/tests/integration/db/payment-methods-backfill.integration.spec.js
implements: []
implements_parts: []
environment: local
implementation_state: implemented
latest_result: not-run
latest_run_at: null
latest_run_ref: null
conformance: not-verified
estimated_minutes: 3
isolation: >-
  Suite-marked records in the prepared local test database; fixture teardown
  removes owned records.
provenance: test
source: >-
  services-accounting:modules/transactions/tests/integration/db/payment-methods-backfill.integration.spec.js
evidence:
  - provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/db/payment-methods-backfill.integration.spec.js
    assertion_titles:
      - >-
        the backfill of payment methods onto payments and intents (the WP-01
        migration against seeded rows)
      - >-
        rewrites an imported row’s status on a plain UPDATE while the status
        trigger is on, the premise of the disable
      - the block run
      - >-
        gives every tenant with a unit, a payment or an intent, and every tenant
        Platform lists, the five system methods
      - writes the system methods with their behaviours and settings
      - >-
        gives the other method, not a system one, to the tenant that recorded an
        other payment and to no other tenant
      - names every payment’s method and behaviour from its retired value
      - names every intent’s method and behaviour from its method kind
      - 'leaves every payment’s status as it was, the imported row’s included'
      - >-
        leaves the status trigger enabled and the write-once and text triggers
        dropped, for the migration to create again
      - writes nothing more when it runs again
    imports:
      - 'const { readFileSync } = require(''node:fs'');'
      - 'const { resolve } = require(''node:path'');'
      - 'const { expect } = require(''chai'');'
      - 'const { sql } = require(''drizzle-orm'');'
      - >-
        const { fixtureDb, ready } =
        require('../../../../books/tests/integration/support');
    test_double_declarations: []
---

# Payment methods backfill suite

## Verification Boundary

The suite exercises transaction commands and database protections in the local prepared test environment. Registration records the existing executable file; it does not report a run or establish product approval.

## What This Suite Proves

The executable assertions exercise this module, but no capability or feature scenario binding is established for this file. Its individual assertion titles remain in the evidence register for subsequent mapping.

## What It Does Not Prove

Local commands and route invocations do not establish deployed routing, live processor guarantees or the complete staff browser experience. An unbound feature chain remains proposed, and this registration carries no execution result.

## Real Dependencies and Test Doubles

The suite uses the imported commands, route handlers or persistence code against the local test database. Fixture helpers supply accounting context; any stepped clock, dummy processor or substituted external client is retained in the evidence declarations.

## Must Not Be Doubled

The command or persistence behavior under assertion and its relevant database protections must remain real. Substituting the final financial result removes evidence of transactional effects.
