Testing Quality Guardrails Implementation

Audience: test-automation leads and the platform team planning CI quality-gate work across Stella Ops.

Overview

This document is the master implementation plan for the Testing Quality Guardrails system, derived from the Testing and Quality Guardrails Technical Reference product advisory.

Source advisorydocs/product/advisories/14-Dec-2025 - Testing and Quality Guardrails Technical Reference.md
Implementation statusPlanning complete, execution pending

Executive Summary

This implementation closes the gaps between the product advisory and the current Stella Ops codebase. After analysis, we identified six high-value items to implement across four focused sprints.

What We’re Implementing

ItemSprintValueEffort
Reachability quality gates in CI0350HIGHLOW
TTFS regression tracking0350HIGHLOW
Performance SLO enforcement0350HIGHLOW
SCA Failure Catalogue (FC6-FC10)0351HIGHMEDIUM
Security testing (OWASP Top 10)0352HIGHMEDIUM
Mutation testing (Stryker.NET)0353MEDIUMMEDIUM

What We’re NOT Implementing (and Why)

ItemReason
toys/svc-XX/ directory restructureAlready have equivalent in src/__Tests/reachability/corpus/
labels.yaml per-service formatAlready have reachgraph.truth.json with same semantics
Canonical TAG formatCan adopt incrementally, not blocking
Fix validation 100% pass rateToo rigid; changed to 90% for fixable cases
Automated reviewer rejectionOver-engineering; human judgment needed

Sprint Roadmap

┌─────────────────────────────────────────────────────────────────┐
│                    TESTING QUALITY GUARDRAILS                    │
├─────────────────────────────────────────────────────────────────┤
│                                                                  │
│  Sprint 0350                Sprint 0351                          │
│  CI Quality Gates           SCA Failure Catalogue                │
│  ┌─────────────┐            ┌─────────────┐                     │
│  │ Reachability│            │ FC6: Java   │                     │
│  │ TTFS        │            │ FC7: .NET   │                     │
│  │ Performance │            │ FC8: Docker │                     │
│  └─────────────┘            │ FC9: PURL   │                     │
│       │                     │ FC10: CVE   │                     │
│       │                     └─────────────┘                     │
│       │                          │                              │
│       └──────────┬───────────────┘                              │
│                  │                                               │
│                  ▼                                               │
│  Sprint 0352                Sprint 0353                          │
│  Security Testing           Mutation Testing                     │
│  ┌─────────────┐            ┌─────────────┐                     │
│  │ OWASP Top 10│            │ Stryker.NET │                     │
│  │ A01-A10     │            │ Scanner     │                     │
│  │ 50+ tests   │            │ Policy      │                     │
│  └─────────────┘            │ Authority   │                     │
│                             └─────────────┘                     │
│                                                                  │
└─────────────────────────────────────────────────────────────────┘

Execution Order

  1. Sprint 0350 and Sprint 0351 can run in parallel (no dependencies)
  2. Sprint 0352 can run in parallel with 0350/0351
  3. Sprint 0353 should start after 0352 (security tests should be stable first)

Estimated Duration

SprintTasksEstimated Effort
0350102-3 developer-days
0351103-4 developer-days
0352104-5 developer-days
0353103-4 developer-days
Total4012-16 developer-days

Sprint Details

Sprint 0350: CI Quality Gates Foundation

File: docs/implplan/SPRINT_0350_0001_0001_ci_quality_gates_foundation.md

Objective: Connect existing test infrastructure to CI enforcement

Key Deliverables:

Quality Thresholds:

thresholds:
  runtime_dependency_recall: >= 0.95
  unreachable_false_positives: <= 0.05
  reachability_underreport: <= 0.10
  ttfs_regression: <= +10% vs main

Sprint 0351: SCA Failure Catalogue Completion

File: docs/implplan/SPRINT_0351_0001_0001_sca_failure_catalogue_completion.md

Objective: Complete FC6-FC10 test cases for scanner regression testing

New Failure Cases:

IDNameFailure Mode
FC6Java Shadow JARShaded dependencies not detected
FC7.NET Transitive PinningCPM pins to vulnerable version
FC8Docker Multi-Stage LeakageBuild-time deps in runtime analysis
FC9PURL Namespace Collisionnpm vs pypi same package name
FC10CVE Split/MergeSingle vuln with multiple CVE IDs

Key Deliverables:


Sprint 0352: Security Testing Framework

File: docs/implplan/SPRINT_0352_0001_0001_security_testing_framework.md

Objective: Systematic OWASP Top 10 coverage for Stella Ops

Coverage Matrix:

OWASPCategoryTest Count
A01Broken Access Control8+
A02Cryptographic Failures6+
A03Injection10+
A05Security Misconfiguration6+
A07Authentication Failures8+
A08Integrity Failures5+
A10SSRF8+
Total7 categories50+ tests

Key Deliverables:


Sprint 0353: Mutation Testing Integration

File: docs/implplan/SPRINT_0353_0001_0001_mutation_testing_integration.md

Objective: Measure test suite effectiveness with Stryker.NET

Target Modules:

ModuleThreshold (Break)Threshold (High)
Scanner.Core60%85%
Policy.Engine60%85%
Authority.Core65%90%

Key Deliverables:


Existing Infrastructure Mapping

The advisory describes structures that already exist under different names:

Advisory StructureExisting EquivalentNotes
toys/svc-XX/src/__Tests/reachability/corpus/Same purpose, different path
labels.yamlreachgraph.truth.jsonDifferent schema, same semantics
evidence/trace.jsonEvidence in attestor moduleAlready implemented
PostgresFixturePostgresIntegrationFixtureAlready implemented
FakeTimeProviderAuthority tests, ConnectorTestHarnessAlready used
inputs.lockExists in acceptance/guardrailsAlready implemented

Quality Gate Summary

After implementation, CI will enforce:

Reachability Gates

Performance Gates

TTFS Gates

Coverage Gates

Security Gates


File Changes Summary

New Files

scripts/ci/
├── compute-reachability-metrics.sh
├── compute-ttfs-metrics.sh
├── enforce-performance-slos.sh
├── enforce-thresholds.sh
├── enforce-mutation-thresholds.sh
├── extract-mutation-score.sh
├── reachability-thresholds.yaml
└── mutation-thresholds.yaml

src/__Tests/__Benchmarks/baselines/
├── ttfs-baseline.json
└── mutation-baselines.json

tests/
├── fixtures/sca/catalogue/
│   ├── fc6-java-shadow-jar/
│   ├── fc7-dotnet-transitive-pinning/
│   ├── fc8-docker-multistage-leakage/
│   ├── fc9-purl-namespace-collision/
│   └── fc10-cve-split-merge/
└── security/
    └── StellaOps.Security.Tests/

.gitea/workflows/
├── security-tests.yml
└── mutation-testing.yml

.config/
└── dotnet-tools.json (stryker)

stryker-config.json (root)

src/Scanner/__Libraries/StellaOps.Scanner.Core/stryker-config.json
src/Policy/StellaOps.Policy.Engine/stryker-config.json
src/Authority/StellaOps.Authority.Core/stryker-config.json

docs/technical/testing/
├── ci-quality-gates.md
├── security-testing-guide.md
└── mutation-testing-guide.md

Modified Files

.gitea/workflows/build-test-deploy.yml
src/__Tests/fixtures/sca/catalogue/inputs.lock
src/__Tests/fixtures/sca/catalogue/README.md
README.md (badges)

Rollback Strategy

If quality gates cause CI instability:

  1. Immediate: Set failure_mode: warn in threshold configs
  2. Short-term: Remove needs: dependencies to unblock other jobs
  3. Investigation: Create issue with specific threshold that failed
  4. Resolution: Either fix underlying issue or adjust threshold
  5. Re-enable: Set failure_mode: block after verification

Success Metrics

MetricCurrentTargetMeasurement
FC Catalogue coverage5 cases10 casesCount of fixtures
Security test coveragePartial50+ testsOWASP categories
Mutation score (Scanner)Unknown≥ 70%Stryker weekly
Mutation score (Policy)Unknown≥ 70%Stryker weekly
Mutation score (Authority)Unknown≥ 80%Stryker weekly
Quality gate pass rateN/A≥ 95%CI runs

References

Sprint Files

Source Advisory

Existing Documentation


Document Version

FieldValue
Version1.0
Created2025-12-14
AuthorPlatform Team
StatusPlanning Complete