---
id: TST-COM-ORD-039
title: 'The checkout tables (integration, table)'
kind: integration
product_area: commerce
module: orders
revision: 1
status: draft
source_sha:
  services-commerce: c8b66a98e2490617aec38ba5c8165dd9bd0a8f9b
repository: services-commerce
files:
  - modules/checkout/tests/integration/db/checkouts.table.integration.spec.js
implements: []
environment: local
implementation_state: implemented
latest_result: not-run
latest_run_at: null
latest_run_ref: null
conformance: not-verified
estimated_minutes: 2
isolation: The suite creates its own test workspace records and removes them using the fixture cleanup.
evidence:
  - provenance: test
    source: 'services-commerce:modules/checkout/tests/integration/db/checkouts.table.integration.spec.js'
    test_cases:
      - 'holds the checkout, open, its padded process ref trimmed and its coupon codes empty (premise)'
      - 'refuses an id that is not a UUIDv7, by checkouts_id_uuid_check'
      - 'refuses a status outside the lifecycle, by checkouts_status_check'
      - 'refuses a placed checkout without its order, and an open one with one, by checkouts_placed_order_check'
      - 'refuses a store the tenant does not have, by checkouts_store_fk'
      - 'refuses the other tenant’s ordering profile, because the key is composite through the tenant'
      - 'refuses a payload past 256 KiB, by checkout_items_payload_size_check'
      - 'refuses a checkout the tenant does not have, by checkout_items_checkout_fk'
      - 'refuses a quantity of zero, by checkout_items_quantity_check'
      - lets the application role insert an event (premise)
      - 'refuses the application role an UPDATE of an event, 42501'
      - 'refuses the application role a DELETE of an event, 42501'
      - 'takes its items and its events with it, the events through the owner’s cascade'
      - 'shows a tenant only its own rows, with no predicate in the statement, and nothing of the other tenant'
      - refuses a checkout written into another tenant
scenario_coverage: []
dependency_evidence:
  provenance: test
  source: 'services-commerce:modules/checkout/tests/integration/db/checkouts.table.integration.spec.js'
  declared_by_test: 'PostgreSQL built from the migrations, both roles, the execution context''s transaction. Doubled: nothing.'
---

# The checkout tables (integration, table)

## Verification Boundary

The suite exercises persistence or workflow operations against the local integration database.

## What This Suite Proves

The registered cases check the checkout tables (integration, table) with their fixture records and assertions. Scenario bindings name only the examples those cases exercise.

## What It Does Not Prove

A registered file supplies no run result or verified conformance by itself. Local fixtures do not establish deployed cross-service behavior or complete browser journeys.

## Real Dependencies and Test Doubles

PostgreSQL and the exercised Commerce persistence or workflow code are real. Remote service records, clocks and transports follow the suite’s fixtures.

## Must Not Be Doubled

The database constraints, role restrictions, locks and transactions exercised by this suite must use PostgreSQL.
