---
id: TST-PFM-ELG-429
title: Eligibility crm conditions checks
kind: integration
product_area: platform
module: eligibility
revision: 1
status: draft
source_sha:
  services-platform: ad3f6a6582843008ed0f5a17b131878d15829af1
repository: services-platform
files:
  - >-
    modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js
implements:
  - ATS-PFM-ELG-008-04
environment: local
implementation_state: implemented
latest_result: not-run
conformance: not-verified
estimated_minutes: 5
isolation: Prepared local test database with suite-owned fixture keys and cleanup.
evidence:
  - provenance: test
    source: >-
      services-platform:modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js
    cases:
      - >-
        answers each contact by its preferred address when the rule names no
        addressType
      - >-
        answers a contact with no address as not meeting the rule, its country
        NULL (DEF-ELIG-0277)
      - answers each contact by its home address when the rule names it
      - 'compiles the binding’s plan, the country list spelled with is'
      - answers the contact too young as ineligible
      - >-
        says the requirement once and names the date of birth the statement read
        (DEF-ELIG-0282)
      - 'premise: the binding’s plan was had while the field was live'
      - >-
        answers the plan as an illegal operation naming the field, not a bad
        request (DEF-ELIG-0283)
      - >-
        answers an evaluation indeterminate, the closed policy deciding the
        outcome, never an error (DEF-ELIG-0283)
      - >-
        lets an open-with-review binding’s policy decide the same indeterminate
        evaluation
      - 'premise: the binding’s plan was had while the dataset was registered'
      - >-
        answers the plan as an illegal operation naming the dataset, not a 404
        (DEF-ELIG-0010)
      - >-
        answers an evaluation indeterminate, the closed policy deciding the
        outcome, never an error (DEF-ELIG-0010)
      - >-
        lets an open-with-review binding’s policy decide the same indeterminate
        evaluation (DEF-ELIG-0010)
      - answers a contact by the roles it holds in an affiliation in force
      - >-
        validates the role condition on each member of a related node over the
        affiliations
      - >-
        names the role by its label in the summary, not by its id
        (DEF-ELIG-0050)
      - keeps the id in the summary when the role cannot be read (DEF-ELIG-0050)
      - >-
        answers any, all, none, at least 2 and exactly 1 by the members that
        hold the role
      - >-
        answers the affiliated contact eligible and the unaffiliated one
        ineligible
      - >-
        names the organization by its name, not its id, for a contact that is
        affiliated and for one that is not (DEF-ELIG-0284)
      - names every organization of an any-of condition (DEF-ELIG-0284)
      - names the contact role by its label (DEF-ELIG-0284)
      - 'names the affiliation types of an affiliation in force, not their ids'
      - keeps the id of an affiliation type that cannot be read
      - says an affiliation in force of any type without settings
      - names the organization an is comparison holds
      - >-
        validates an affiliation type rule and an is comparison on a reference
        with no problem
      - >-
        evaluates is on a reference field as the contact being affiliated with
        that organization
      - >-
        evaluates is_not on a reference field as an affiliation in force with
        another organization
      - answers every evaluation indeterminate with the one reason read_failed
      - lets each binding’s fail policy decide the outcome
      - logs the failed read with the database’s SQLSTATE
      - counts the failed read under platform.eligibility.read.failed.count
      - >-
        answers the transactional check indeterminate, read_failed, ineligible
        under the closed policy
      - >-
        records the transactional decision in the caller’s transaction after the
        failed read
  - provenance: documented
    source: >-
      services-platform:modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js:suite
      header
    note: >-
      The source header describes the verification boundary and declared
      substitutions.
proof_limit: >-
  Only the named scenario checkpoints have a verified source binding; execution
  has not been attempted.
---

# Eligibility crm conditions checks

## Verification Boundary

This suite checks the module through real local service and database code at the entry points used by its test cases.

## What This Suite Proves

The mapped scenarios identify the capability and feature checkpoints this file exercises. The source test titles preserve the assertion-level evidence.

## What It Does Not Prove

Registration supplies no execution result or conformance decision. Checks beyond the file’s reachable assertions remain unverified, including production configuration.

## Real Dependencies and Test Doubles

The suite uses local integration fixtures. Signing, caches, provider responses or outbound delivery may be supplied by fixtures where the source declares a substitution. The source imports and suite header identify the exact dependencies.

## Must Not Be Doubled

The module behavior under assertion, transaction boundary and database constraint being checked remain real. Fixture setup cannot stand in for the asserted write or refusal.
