1---2name: sifap-tests-23description: Requires SIFAP tests to prove requirement and legacy-behavior coverage with deterministic, privacy-safe fixtures. Use when editing backend, frontend, integration, or equivalence tests.4---56<!-- Generated from harness/github-copilot/plugins/mainframe-natural-adabas-classic/instructions/sifap-tests.instructions.md by harness/claude-code/scripts/convert_from_copilot.py. Edit the source, not this file. -->78# SIFAP test conventions - Requirements and equivalence910These instructions apply to SIFAP automated tests. They are authoritative for requirement lineage,11behavior oracles, determinism, and privacy; the target repository's test framework and configured quality12gates define executable commands and numeric thresholds.1314## Coverage and oracles1516- Cite `REQ-NNN` in tests that verify an approved requirement.17- Prioritize requirement, risk, boundary, negative, error, and legacy-equivalence coverage.18- Use line or branch thresholds only when configured in the real build; do not invent 60, 80, or 10019 percent goals in a primitive.20- Capture legacy behavior before transformation and classify every modernized difference.21- Use Testcontainers for PostgreSQL semantics when persistence behavior matters.2223## Determinism and privacy2425- Control time, randomness, locale, ordering, concurrency, and external responses.26- Use synthetic fixtures and never copy production CPF, benefit amounts, credentials, or records.27- Compare financial values with exact decimal semantics.28- Write assertions that fail on a real behavior defect; reject tautologies and snapshot-only evidence.2930## Conventions3132| Rule | Rationale |33| --- | --- |34| Trace tests to `REQ-NNN` | Requirement coverage stays reviewable. |35| Pin legacy behavior before rewrite | Drift becomes executable evidence. |36| Use configured thresholds only | Primitives do not fabricate quality policy. |37| Keep fixtures deterministic and synthetic | Suites remain trustworthy and privacy-safe. |3839## Do / Do Not4041| Do | Do not |42| --- | --- |43| Run a focused test before the broader suite | Claim green from compilation alone |44| Test observable behavior | Assert private implementation details |45| Record intentional differences | Update golden masters merely to pass |46| Report flaky tests as defects | Skip or weaken tests to force green |4748## Checklist Before Opening a PR4950- [ ] Changed behavior maps to approved requirements or explicit characterization evidence.51- [ ] Tests cover positive, boundary, negative, error, and drift paths as risk requires.52- [ ] Fixtures are deterministic, synthetic, and free of sensitive data.53- [ ] Assertions can fail on meaningful behavior changes.54- [ ] Focused and broader relevant suites pass, or exact blockers are reported.55- [ ] Coverage claims use repository configuration and actual reports.