---
id: TST-PFM-SEC-265
title: Workspace provisioning mapper unit checks
kind: unit
product_area: platform
module: security
revision: 2
status: draft
source_sha:
  services-platform: ad3f6a6582843008ed0f5a17b131878d15829af1
repository: services-platform
files:
  - modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts
implements:
  - ATS-PFM-SEC-003-02
environment: mock
implementation_state: implemented
latest_result: not-run
latest_run_at: null
latest_run_ref: null
conformance: not-verified
estimated_minutes: 1
isolation: The suite owns its input fixtures and installed doubles.
assertion_evidence:
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#the
      ids POST /tenants takes
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#carries
      the tenant id the request names
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#stores
      what a person typed in its one form, trimmed and lowercase
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#carries
      a sandbox id with dots
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#carries
      ids with hyphens and underscores
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#carries
      the id of the customer the same request creates, normalized
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#puts
      the tenant in the customer it creates, so the two agree
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#lets
      the tenant and the customer it creates share an id, an association being its own customer
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#the
      ids POST /tenants refuses
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#refuses
      a request that names no tenant id, naming the property
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a missing tenant id tenant_id_required
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a UUID-shaped tenant id tenant_id_invalid
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a tenant id with two dots together tenant_id_invalid
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a reserved tenant id tenant_id_reserved
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#refuses
      a new customer that names no id, naming new_customer.id
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a new customer that names no id customer_id_required
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#codes
      a new customer with a UUID-shaped id customer_id_invalid
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#refuses
      a request that both creates a customer and names one, the tenant belonging to one customer
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#refuses
      a request that says nothing about the customer, naming the property it is missing
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#the
      properties POST /tenants no longer takes
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#refuses
      a body that sends domain, a property a tenant no longer has, naming it
  - provenance: test
    source: >-
      services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts#accepts
      the same body without it, the negative control
dependency_evidence: >-
  The production function, schema or declaration runs over literal inputs. The source declares no
  substituted collaborator; this is an in-process decision or mapping check.
evidence:
  - 'services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts'
  - >-
    Static review at the recorded source revision; executable results remain not-run and conformance
    remains not-verified.
binding_note: >-
  Each binding names the scenario to which this file contributes assertions. A binding is not a
  recorded pass and does not extend the file’s dependency boundary.
examiner: codex
examined_at: '2026-10-23'
final_text: OpenAI
dependency_review:
  provenance: test
  source: 'services-platform:modules/tenants/tests/unit/aws/api/tenant-provisioning-mapper.spec.ts'
  explicit_no_doubles: true
  identified_double_boundaries: []
---
# Workspace provisioning mapper unit checks

## Verification Boundary

The file evaluates production helpers with controlled inputs in-process. The assertion references identify the source checks for workspace provisioning mapper.

## What This Suite Proves

The source assertions support the observations named in the bound scenarios. A scenario spanning multiple files must retain the other files’ contributions.

## What It Does Not Prove

This examination does not run the suite. Passing behavior, deployed conformance and the behavior of substituted dependencies require separate execution evidence.

## Real Dependencies and Test Doubles

The production function, schema or declaration runs over literal inputs. The source declares no substituted collaborator; this is an in-process decision or mapping check.

## Must Not Be Doubled

Keep the production helper, schema, matcher or declaration under examination real. Substituting the decision itself would remove the behavior the assertions exercise.
