---
id: TST-ACC-TRX-075
title: Integrations electronic check 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/services/payments/integrations-electronic-check.integration.spec.js
implements:
  - ATS-ACC-TRX-007-09
implements_parts:
  - scenario: ATS-ACC-TRX-007-09
    assertion: >-
      it records the payment pending_settlement on the electronic_check method:
      the account’s last four, no card brand
    provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/services/payments/integrations-electronic-check.integration.spec.js#it
      records the payment pending_settlement on the electronic_check method: the
      account’s last four, no card brand
  - scenario: ATS-ACC-TRX-007-09
    assertion: >-
      it settles the one the authorization reads cleared: succeeded, its capture
      item eligible
    provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/services/payments/integrations-electronic-check.integration.spec.js#it
      settles the one the authorization reads cleared: succeeded, its capture
      item eligible
  - scenario: ATS-ACC-TRX-007-09
    assertion: 'it returns the one the authorization reads failed, as an ACH return'
    provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/services/payments/integrations-electronic-check.integration.spec.js#it
      returns the one the authorization reads failed, as an ACH return
  - scenario: ATS-ACC-TRX-007-09
    assertion: 'it settles the third by the event the gateway sends, found by its subject'
    provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/services/payments/integrations-electronic-check.integration.spec.js#it
      settles the third by the event the gateway sends, found by its subject
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/services/payments/integrations-electronic-check.integration.spec.js
evidence:
  - provenance: test
    source: >-
      services-accounting:modules/transactions/tests/integration/services/payments/integrations-electronic-check.integration.spec.js
    assertion_titles:
      - an electronic check through the Payrix gateway (integration)
      - >-
        charges the token as an electronic check: tokenized, then authorized
        with the feature ach (premise)
      - >-
        records the payment pending_settlement on the electronic_check method:
        the account’s last four, no card brand
      - 'holds the capture item until the money clears, and the intent succeeded'
      - clearing
      - >-
        settles the one the authorization reads cleared: succeeded, its capture
        item eligible
      - 'returns the one the authorization reads failed, as an ACH return'
      - payments.payment.updated
      - 'settles the third by the event the gateway sends, found by its subject'
    imports:
      - 'const { stage } = require(''@rhythmsoftware/macroservice-testing/stage'');'
      - >-
        const { manualClock } =
        require('@rhythmsoftware/macroservice-time/clock');
      - >-
        const { TEST_NOW } =
        require('@rhythmsoftware/macroservice-testing/execution-context');
      - >-
        const { localIntegrationTransport, stubInvokeResult } =
        require('@rhythmsoftware/integration-client/local');
      - 'const { sql } = require(''drizzle-orm'');'
      - >-
        const { applyIntegrationEvents } =
        require('../../../../services/integrations/integration-events');
      - >-
        const { sweepProcessingIntents } =
        require('../../../../services/payments/intent-sweeper');
      - >-
        const { useIntegrationInvokeOptionsForTests } =
        require('../../../../services/payments/integrations-processor');
      - >-
        const { receivePayment } =
        require('../../../../services/payments/payment-receive');
      - '} = require(''../../payments-fixtures'');'
      - "\t\ttendered.require();"
      - "\t\tconst { clears } = tendered.require();"
      - "\t\tconst { clears } = tendered.require();"
      - "\t\t\tconst { clears, returns } = tendered.require();"
      - "\t\t\tconst { clears } = tendered.require();"
      - "\t\t\texpect(swept.require().settled).to.include(clears.id);"
      - "\t\t\tconst { returns } = tendered.require();"
      - "\t\t\texpect(swept.require().returned).to.include(returns.id);"
      - "\t\t\tconst { event } = tendered.require();"
    test_double_declarations: []
---

# Integrations electronic check 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

Its cited assertions contribute evidence for bank clearing finishes pending receipts. The structured assertion bindings identify which parts of combined scenarios it executes.

## 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.
