Skip to content

ATS-PFM-ELG-008Determine eligibility with an explanation: Capability Test Specification

Markdown

ATS-PFM-ELG-008

Determine eligibility with an explanation: Capability Test Specification

Markdown
  • DocumentProposed

KindAcceptance test setProduct areaPlatformModuleEligibility, Responsibilities and AttentionRevision3

Read atservices-platform ad3f6a65react-console baf6dae3

Coverage

  • Rule covered
  • Transition gap: FND-PFM-ELG-060
  • Validation covered
  • Permission gap: FND-PFM-ELG-060
  • Edge covered
  • Failure covered
  • Boundary covered
  • Concurrency gap: FND-PFM-ELG-060
  • Invariant gap: FND-PFM-ELG-060
  • Interaction covered

Test Scenarios

19 scenarios proving CAP-PFM-ELG-008; 14 bound to an existing test.

01 Interpret uncertainty per useruleunittest
Proves
BR-CAP-PFM-ELG-008-01
Preconditions
An expression produces an indeterminate result.
Steps
Evaluate with all three failure policies.
Expected
Closed denies, open-with-review admits with a flag and defer supplies no outcome.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state ineligible under closed
services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state eligible with review under open_with_review, in either spelling
services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#gives an indeterminate state no outcome under defer
Source
services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state ineligible under closed
02 Verify subjects before factsinvariantapinegativetest
Proves
BR-CAP-PFM-ELG-008-02 INV-DOM-PFM-ELG-003-05
Preconditions
A fact-only expression is asked about present and absent contacts.
Steps
Evaluate ordinarily, transactionally and through SQL.
Expected
Absent contacts are indeterminate with not-found reasoning and closed-policy denial; present contacts follow the expression.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers a contact no row of the tenant has indeterminate, subject_not_found, ineligible under the closed policy
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers a batch mixing existing and missing contacts each by its own existence
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers the SQL function eligible for an existing contact and subject_not_found for a missing one
services-platform:modules/eligibility/tests/unit/subject-existence.spec.js#answers an eligible fold indeterminate, UNKNOWN, subject_not_found when a subject is missing
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers a contact no row of the tenant has indeterminate, subject_not_found, ineligible under the closed policy
03 Detect omitted subjectsvalidationapinegativetest
Proves
BR-CAP-PFM-ELG-008-03
Preconditions
A rule requires its primary subject.
Steps
Omit it and send it empty.
Expected
Both yield a missing-subject indeterminate result and closed-policy denial.
Data
No fixtures beyond the described setup.
Bound to
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/plat-m11-evaluation.integration.spec.js#answers indeterminate with the reason subject_missing
04 Convert read failures into resultsfailureapinegativetest
Proves
BR-CAP-PFM-ELG-008-04
Preconditions
One evaluation dataset fails its read.
Steps
Request a batch.
Expected
Affected entries return read-failure uncertainty under policy and unaffected entries still answer.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js#answers the transactional check indeterminate, read_failed, ineligible under the closed policy
services-platform:modules/eligibility/tests/unit/crm-declarations.spec.js#answers each evaluation indeterminate with the one reason read_failed
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js#answers every evaluation indeterminate with the one reason read_failed
05 Treat empty records as unmet conditionsedgeapitest
Proves
BR-CAP-PFM-ELG-008-05
Preconditions
Contacts have matching and absent addresses.
Steps
Evaluate the country condition.
Expected
The matching record qualifies and the empty address fails with not-satisfied reasoning.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/plat-m11-evaluation.integration.spec.js#answers a contact with no address ineligible, not_satisfied, never fact_missing
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/plat-m11-evaluation.integration.spec.js#premise: a contact with a US address meets the rule
06 Resolve dates relative to the questionboundaryapitest
Proves
BR-CAP-PFM-ELG-008-06
Preconditions
A currently adult contact was under 18 in the earlier year.
Steps
Evaluate today, in the earlier year and around the birthday.
Expected
The earlier answer differs appropriately and the birthday changes the result on its day.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers an as-of shift from the day asked about, so a contact adult today was not in 2015
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers an as-of shift from the day asked about, so a contact adult today was not in 2015
07 Bound ordered batchesboundaryapinegativetest
Proves
BR-CAP-PFM-ELG-008-07
Preconditions
A directory supplies evaluation subjects.
Steps
Request batches of one, two, 50 and 51.
Expected
Valid results preserve order and the excessive batch is rejected whole.
Data
No fixtures beyond the described setup.
Bound to
Source
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#answers the batch’s decisions in the order asked
08 Apply caller admissionpermissionunitnegativetest
Proves
BR-CAP-PFM-ELG-008-08
Preconditions
Purposes admit portal, console or system contexts.
Steps
Request each as members, staff and services.
Expected
Admission follows purpose rules with read authority required for staff and services.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a console caller holding the read key a binding whose consumer kind takes system callers only, 403
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a portal member a binding whose consumer kind takes no portal callers, 403
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#refuses a service caller a kind that declares no system callers
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#needs the engine’s read key for a kind that declares no key of its own
Source
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a console caller holding the read key a binding whose consumer kind takes system callers only, 403
09 Constrain portal questionspermissionapinegativetest
Proves
BR-CAP-PFM-ELG-008-09
Preconditions
Members include linked and unlinked accounts.
Steps
Ask about self, another subject or actor, stronger consistency and an unlinked account.
Expected
Only the self display question succeeds and its facts remain asserted.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a portal member an evaluation of another contact, 403
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a portal member another contact named as the actor, 403
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a portal member an authorization evaluation, 403
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a portal caller whose sign-in is linked to no contact, 403
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#makes every fact asserted, whatever trust it claimed
Source
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#fills actorContact from the member’s own contact
10 Reject excessive explanation requestspermissionapinegativetest
Proves
BR-CAP-PFM-ELG-008-10
Preconditions
Portal and staff callers have differing read authority.
Steps
Request all explanation levels.
Expected
Basic levels are available; administrator and full require read authority and exclude portal, with no silent downgrade.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#refuses a portal caller the full explanation even with the read permission
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#refuses a console caller without the read permission the admin explanation
Source
services-platform:modules/eligibility/tests/unit/evaluate-for-caller.spec.js#refuses a portal caller the full explanation even with the read permission
11 Explain with permitted labelsruleapitest
Proves
BR-CAP-PFM-ELG-008-11
Preconditions
Inactive status, a country value and closed-policy uncertainty are represented.
Steps
Request administrator, full and portal explanations.
Expected
Status names explain held and required values, full detail includes the country and the uncertain portal result uses configured wording.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#gives the portal the definition’s message for an indeterminate decision under the closed policy
services-platform:modules/eligibility/tests/integration/services/evaluate/plat-m11-evaluation.integration.spec.js#keeps the country out of the portal sentence, which is generic for an address
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#gives the portal the definition’s message for an indeterminate decision under the closed policy
12 Share transactional visibilityinteractionapinegativetest
Proves
BR-CAP-PFM-ELG-008-12
Preconditions
A contact is inserted inside an open transaction.
Steps
Evaluate there and through SQL, then try a person’s transactional web request.
Expected
The in-process result sees the row and records atomically, SQL agrees and the web request fails.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers the SQL function’s states the TypeScript path answers for the planted contacts
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#refuses a transactional evaluation, naming evaluateInTransaction, 400
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#sees a contact inserted earlier in the same transaction
13 Bound provider workfailureapinegativetest
Proves
BR-CAP-PFM-ELG-008-13
Preconditions
A provider declares batching and timeout support.
Steps
Evaluate multiple subjects, delay it and cause five failures.
Expected
Declared batches apply, timeout produces uncertainty and the open circuit stops further provider calls.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#asks the provider in batches of its declared size with the batch payload
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#opens the circuit after five failures and calls the provider no more while it is open
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#asks the provider in batches of its declared size with the batch payload
14 Prevent data-reader writespermissionapinegativetest
Proves
BR-CAP-PFM-ELG-008-14
Preconditions
The eligibility reader has reporting access.
Steps
Evaluate without a direct CRM grant and attempt contact mutation as the reader.
Expected
Reporting access supplies evaluation data and every mutation is rejected.
Data
No fixtures beyond the described setup.
Bound to
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers a sql condition over crm.contacts with no grant to the eligibility reader in crm
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#is a member of the query reader that inherits its privileges
15 Compare trial and consumer answersinteractionapiproposed
Proves
BR-CAP-PFM-ELG-003-01 BR-CAP-PFM-ELG-008-01
Preconditions
One valid expression and subject are available to a reader and a consumer.
Steps
Try the expression and evaluate a binding to that expression with the same subject and day.
Expected
The condition states agree; only the bound request is eligible for recording and uncertainty policy.
Data
Run-owned records and a controlled clock where timing changes the result.
Source
services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#answers the version’s decision with the trace, never recorded; services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state ineligible under closed
16 Apply availability before uncertainty policyinteractionapinegativeproposed
Proves
BR-CAP-PFM-ELG-007-08 BR-CAP-PFM-ELG-008-01
Preconditions
A valid following use has a cached answer.
Steps
Suspend the use, attempt evaluation under each failure policy, then reactivate compatibly and evaluate again.
Expected
Suspension produces a refusal rather than an ineligible answer; compatible reactivation permits evaluation.
Data
Run-owned records and a controlled clock where timing changes the result.
Source
react-console:acceptance/eligibility/playwright/journeys/bindings/ELIG-ACC-0217.spec.ts#ELIG-ACC-0217; services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state ineligible under closed
17 Record a consequential uncertain answerinteractionapiproposed
Proves
BR-CAP-PFM-ELG-008-02 BR-CAP-PFM-ELG-009-07
Preconditions
A bound authorization request has a missing workspace subject.
Steps
Evaluate under closed policy and inspect the returned decision and history before completing the caller operation.
Expected
The returned decision can be read immediately with its uncertain state, denial outcome and subject reason.
Data
Run-owned records and a controlled clock where timing changes the result.
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#answers a contact no row of the tenant has indeterminate, subject_not_found, ineligible under the closed policy; services-platform:modules/eligibility/tests/integration/services/evaluate/hosted-evaluate.integration.spec.js#records a display decision after answering it, at a sample rate of one
18 Keep display caching separate from authorityinteractionapiproposed
Proves
BR-CAP-PFM-ELG-008-01 BR-CAP-PFM-ELG-010-01
Preconditions
A display answer is cached before its subject changes.
Steps
Evaluate display and authorization requests before the cache expires, then repeat after expiry.
Expected
Authorization reads the changed data immediately and display refreshes at expiry; cache hits add no decision.
Data
Run-owned records and a controlled clock where timing changes the result.
Source
services-platform:modules/eligibility/tests/unit/compile-and-evaluate.spec.js#makes an indeterminate state ineligible under closed; services-platform:modules/eligibility/tests/e2e/eligibility-evaluate.e2e.spec.js#never answers an authorization evaluation from the cache
19 Observe read failure and circuit refusalinteractionapinegativeproposed
Proves
BR-CAP-PFM-ELG-008-04 BR-CAP-PFM-ELG-012-02
Preconditions
A batch has a failing provider entry and a healthy entry.
Steps
Evaluate the batch repeatedly through the circuit threshold and inspect results and diagnostics.
Expected
The failing entry is uncertain, the healthy entry remains answered and circuit diagnostics contain no fact payload.
Data
Run-owned records and a controlled clock where timing changes the result.
Source
services-platform:modules/eligibility/tests/integration/services/evaluate/crm-conditions.integration.spec.js#answers every evaluation indeterminate with the one reason read_failed; services-platform:modules/eligibility/tests/unit/alarm-inputs.spec.ts#reads the circuit refusals under both services that evaluate: the API function’s and the population task’s

The Markdown files under specs/ in rhythmsoftware/rhythm-v2-docs are the canonical source of truth. This reader is a generated, read-only projection of them.