Skip to main content
Version: 3.0.1

STD: ADJ Zika Rule (ADJZIKA)

Version: v1.0.0 Status: Draft SRS Source: docusaurus/docs/srs/rules/rule-adj-zika.md Rule Name: ADJ_Zika Domain: RULES-ADJZIKA


Overview

This document specifies tests for the ADJ Zika rule using decision tables and test vectors. The rule evaluates wells for potential adjacent cross-contamination in Zika PCR assays by comparing observation quantities against configured thresholds.

Rule Characteristics:

  • Pure business logic (no UI)
  • Threshold-based contamination detection
  • Historical suppression for repeat accessions
  • Well ordering logic for same-accession history

Test Method: TM-API (per Test Plan - Rules use automated API tests)

Verification Approach: Rule verification is performed using data-driven test vectors. Each row in a decision table represents a complete verification scenario with defined inputs and expected outputs. This format enables exhaustive condition coverage while remaining concise and auditable.


Coverage Summary

REQ IDTitleConditionsTest VectorsCoverageGaps
REQ-RULES-ADJZIKA-001Apply Adjacent Well Contamination Thresholds816100%None
REQ-RULES-ADJZIKA-002Suppress Errors for Repeat Accessions with Low-Positive History68100%None
REQ-RULES-ADJZIKA-003Use Latest Well Number for Same-Accession History46100%None

Totals: 3 REQs, 18 Conditions, 30 Test Vectors, 100% Coverage


REQ-RULES-ADJZIKA-001: Apply Adjacent Well Contamination Thresholds

Input Variables

VariableTypeValid ValuesDescription
well.mixstringZika, OtherWell mix identifier
well.targetstringZika, OtherWell target identifier
well.quantityfloatnumericObservation quantity of current well
adjacent.quantityfloatnumericObservation quantity of adjacent well
config.POTENTIAL_CONTAMINATEDfloatnumericUpper bound for "at risk" wells
config.POTENTIAL_CONTAMINATINGfloatnumericLower bound for "source" wells
config.QUANT_OR_CTstringQUANT, CTEvaluation mode

Output Variables

VariableTypeDescription
well.error_codestring?ZIKA_ADJ_CT when contamination detected, null otherwise
rule_appliedboolWhether the rule was evaluated for this well

Decision Table: Mix/Target Filter

TVwell.mixwell.targetrule_appliedCovers
TV-001-001ZikaZikatrueAC: Both match rule mapping
TV-001-002ZikaOtherfalseAC: Target mismatch
TV-001-003OtherZikafalseAC: Mix mismatch
TV-001-004OtherOtherfalseAC: Neither match

Decision Table: Threshold Evaluation (QUANT Mode)

TVwell.qtyadj.qtyPOTENTIAL_CONTAMINATEDPOTENTIAL_CONTAMINATINGerror_assignedCovers
TV-001-005100600200400ZIKA_ADJ_CTAC: Both thresholds met
TV-001-006100300200400nullAC: Adjacent below contaminating threshold
TV-001-007300600200400nullAC: Current above contaminated threshold
TV-001-008300300200400nullAC: Neither threshold met

Decision Table: Boundary Conditions

TVwell.qtyadj.qtyPOTENTIAL_CONTAMINATEDPOTENTIAL_CONTAMINATINGerror_assignedCovers
TV-001-009200401200400nullAC: At contaminated threshold (not below)
TV-001-010199400200400nullAC: At contaminating threshold (not above)
TV-001-011199401200400ZIKA_ADJ_CTAC: Just below/just above boundaries
TV-001-01211000000200400ZIKA_ADJ_CTAC: Extreme values

Decision Table: Gap Coverage — Negative Path and Adjacency

TVScenariowell.qtyadj.qtythresholdserror_assignedCovers
TV-ADJZIKA-GAP-001Both wells above contaminated threshold (no at-risk well)high (CT=20)high (CT=20)Neither below POTENTIAL_CONTAMINATEDnullAC: No at-risk well means no flag
TV-ADJZIKA-GAP-002Both wells below contaminating threshold (no source well)moderate (CT=36.5)moderate (CT=36.5)Neither above POTENTIAL_CONTAMINATINGnullAC: No contamination source means no flag
TV-ADJZIKA-GAP-003One above contaminated, other below contaminatinghigh (CT=20)moderate (CT=30)Only one condition metnullAC: Both thresholds must be met
TV-ADJZIKA-GAP-004Non-adjacent wells not flagged (plate ordering)low (CT=36.5)high (CT=15)A1 and H12 (opposite ends)nullAC: Only plate-adjacent wells checked

REQ-RULES-ADJZIKA-002: Suppress Errors for Repeat Accessions with Low-Positive History

Input Variables

VariableTypeValid ValuesDescription
well.accessionstringanyAccession number of current well
history.existsbooltrue, falseWhether historical results exist
history.quantityfloat?null, numericHistorical result quantity
config.POTENTIAL_CONTAMINATEDfloatnumericUpper bound defining low-positive range

Output Variables

VariableTypeDescription
error_suppressedboolWhether ZIKA_ADJ_CT error was suppressed

Decision Table: Historical Suppression Logic

TVhistory.existshistory.qtyPOTENTIAL_CONTAMINATEDcontamination_detectederror_assignedCovers
TV-002-001falsenull200trueZIKA_ADJ_CTAC: No history - apply error
TV-002-002true100200truenullAC: History in low-positive range - suppress
TV-002-003true300200trueZIKA_ADJ_CTAC: History above threshold - apply error
TV-002-004true0200trueZIKA_ADJ_CTAC: History at zero - not in range (qty > 0 required)

Decision Table: Low-Positive Range Boundaries

TVhistory.qtyPOTENTIAL_CONTAMINATEDin_low_positive_rangeCovers
TV-002-0051200trueAC: Just above zero
TV-002-006200200trueAC: At threshold (inclusive)
TV-002-007201200falseAC: Just above threshold
TV-002-008-1200falseAC: Negative (invalid)

REQ-RULES-ADJZIKA-003: Use Latest Well Number for Same-Accession History

Input Variables

VariableTypeValid ValuesDescription
run.wellsarray[Well...]Wells in the run with same accession
well.well_numberstringA1, A2, B1, ...Well position identifier
well.accessionstringanyAccession number

Output Variables

VariableTypeDescription
selected_history_wellstringWell number used as historical reference

Decision Table: Well Ordering (Alphanumeric)

TVwells_same_accessionselected_for_historyCovers
TV-003-001[A1]A1AC: Single well - use that well
TV-003-002[A1, A2]A2AC: A2 > A1
TV-003-003[A1, B1]B1AC: B1 > A1 (row ordering)
TV-003-004[A10, A2, A1]A10AC: Alphanumeric sort (A10 > A2)

Decision Table: History Determination Integration

TVRun1 WellsRun1 SelectedRun2 WellRun2 OutcomeCovers
TV-003-005A1(qty=111K), A2(qty=24)A2(qty=24)A1(qty=24) adjacent to A2(qty=111K)No errorAC: Latest well in range suppresses
TV-003-006A1(qty=24), A2(qty=111K)A2(qty=111K)A1(qty=24) adjacent to A2(qty=111K)ZIKA_ADJ_CTAC: Latest well above range - error applied

Automation Status

REQ IDTest VectorsStatusNotes
REQ-RULES-ADJZIKA-001TV-001-001 to TV-001-012AutomatedThreshold evaluation
REQ-RULES-ADJZIKA-002TV-002-001 to TV-002-008AutomatedHistorical suppression
REQ-RULES-ADJZIKA-003TV-003-001 to TV-003-006AutomatedWell ordering

Traceability to Existing Tests

RequirementJira TestsStatus
REQ-RULES-ADJZIKA-001BT-5155Existing
REQ-RULES-ADJZIKA-002BT-5155, BT-5157Existing
REQ-RULES-ADJZIKA-003BT-5155, BT-5157Existing

Gap Analysis

Identified Gaps

GapRequirementDescriptionPriorityOwner
None-All acceptance criteria covered by test vectors--

Notes

  • All test vectors derived from SRS acceptance criteria and acceptance tests
  • Boundary conditions explicitly tested for threshold comparisons
  • Low-positive range definition (qty > 0 AND qty <= threshold) tested at boundaries
  • Well ordering tested with alphanumeric sort edge cases (A10 vs A2)