← Back to CSV Documentation
COS-CSV-OQ-001Approvedv1.0

Operational Qualification (OQ)

Formal functional testing of all Module 1 features

30/30
Test cases passed
188
Automated E2E tests (all pass)
April 2026
Execution date
TC-001URS-001ClinicalTrials.gov ingestion
PASS
Procedure:

POST /api/v1/ingestion/trigger with mode='daily'. Verify sites created/updated in DB.

Expected result:

HTTP 200, sites count > 0, data_provenance record created

TC-002URS-002PubMed investigator enrichment
PASS
Procedure:

POST /api/v1/ingestion/trigger with enrich_pubmed=true. Verify h_index and pub_count populated.

Expected result:

Investigators updated with h_index > 0

TC-003URS-003Ingestion mode selection
PASS
Procedure:

Trigger daily mode (24h window) and full mode (broad search). Compare record counts.

Expected result:

Daily returns recent updates; full returns comprehensive dataset

TC-004URS-004Data provenance recording
PASS
Procedure:

GET /api/v1/compliance/data-provenance. Verify entries exist with source, hash, record_count.

Expected result:

Provenance records with SHA-256 hashes

TC-005URS-005Composite scoring (5 dimensions)
PASS
Procedure:

GET /api/v1/sites/{id}/score. Verify 5 dimension values and total between 0-100.

Expected result:

score_total = weighted sum of 5 dimensions * 100

TC-006URS-006Score explainability
PASS
Procedure:

GET /api/v1/sites/{id}/score/explain. Verify factors array and source attribution.

Expected result:

Explainability includes factors, sources, confidence

TC-007URS-007Custom weight scoring
PASS
Procedure:

POST /api/v1/sites/{id}/score/customize with custom weights summing to 1.0.

Expected result:

Recalculated score with custom weights, response < 2s

TC-008URS-008Deterministic scoring
PASS
Procedure:

Score same site twice with identical parameters. Compare results.

Expected result:

Identical scores on both runs (no random variance)

TC-009URS-009Structured site search
PASS
Procedure:

POST /api/v1/sites/search with filters: therapeutic_area=Oncology, country=Switzerland.

Expected result:

Results filtered correctly, paginated, org_id isolated

TC-010URS-010Natural language search
PASS
Procedure:

POST /api/v1/sites/search with query='oncology sites in Switzerland with 50+ trials'.

Expected result:

AI interprets query, returns relevant results with synonym expansion

TC-011URS-011Conversational site agent
PASS
Procedure:

POST /api/v1/site-agent with message and session_id. Send follow-up query.

Expected result:

Agent maintains context, returns sites and suggestions

TC-012URS-012Investigator profiles
PASS
Procedure:

GET /api/v1/investigators?page=1&size=10. GET /api/v1/investigators/{id}.

Expected result:

List with h_index, pub_count, trial_count. Detail with all fields.

TC-013URS-013Investigator comparison
PASS
Procedure:

POST /api/v1/investigators/compare with 3 investigator IDs.

Expected result:

Full profiles for all 3 investigators returned

TC-014URS-014PDF/Excel export
PASS
Procedure:

POST /api/v1/exports/sites/pdf and /excel with search filters.

Expected result:

StreamingResponse with correct content-type

TC-015URS-015Project workspace
PASS
Procedure:

POST /api/v1/projects (create). POST /api/v1/projects/{id}/shortlist (add site).

Expected result:

Project created. Site added to shortlist with status.

TC-016URS-016Recruitment prediction
PASS
Procedure:

POST /api/v1/predictions/recruitment with site IDs.

Expected result:

Predictions with optimistic/realistic/pessimistic + confidence

TC-017URS-017Multi-tenancy isolation
PASS
Procedure:

Login as user A (org X), search sites. Login as user B (org Y), search sites.

Expected result:

Each user sees only their org's data. No cross-tenant leakage.

TC-018URS-018JWT authentication
PASS
Procedure:

POST /api/v1/auth/login with valid credentials. Use token for protected endpoint. Wait 15min, verify expiry.

Expected result:

Login returns access + refresh tokens. Protected endpoints work. Expired token returns 401.

TC-019URS-019RBAC enforcement
PASS
Procedure:

Login as read_only user. Attempt POST to admin endpoint.

Expected result:

Admin endpoint returns 403 for read_only user

TC-020URS-020Two-factor authentication
PASS
Procedure:

POST /api/v1/auth/2fa/setup. Verify TOTP code. Login with 2FA.

Expected result:

TOTP setup returns secret + QR URI. Valid code accepted.

TC-021URS-021Immutable audit trail
PASS
Procedure:

Perform POST action. Check audit_log. Attempt UPDATE on audit_log row.

Expected result:

Audit record created. UPDATE blocked by trigger with error message.

TC-022URS-022Audit hash chain integrity
PASS
Procedure:

Query audit_log for org. Verify record_hash matches recomputed hash. Verify prev_hash chain.

Expected result:

Hash chain intact. Each prev_hash matches previous record's record_hash.

TC-023URS-023Encryption verification
PASS
Procedure:

SHOW ssl (DB). Check pgcrypto extension. List encrypted columns.

Expected result:

SSL on. pgcrypto installed. 6 encrypted columns found.

TC-024URS-024Search response time
PASS
Procedure:

Run site search 10 times, measure p95 latency.

Expected result:

p95 < 5 seconds for up to 500 results

TC-025URS-025Availability SLA
PASS
Procedure:

Check /health endpoint every 5 minutes over 24 hours.

Expected result:

100% uptime during test period

TC-026URS-026AI model registry
PASS
Procedure:

GET /api/v1/ai-modules/registry. Verify models listed with versions.

Expected result:

Registry contains model entries with versioned IDs

TC-027URS-027AI audit log
PASS
Procedure:

GET /api/v1/ai-explain/audit-log. Verify inference entries.

Expected result:

Audit entries with input_hash, output_hash, model_id

TC-028URS-028Disclaimer display
PASS
Procedure:

Navigate to /legal/disclaimer. Check sidebar badges.

Expected result:

Disclaimer page loads. Module 1 shows 'Validated' badge.

TC-029URS-029i18n language switching
PASS
Procedure:

Switch language to FR, DE, JA. Verify UI labels change.

Expected result:

Labels translated. Fallback to EN for missing keys.

TC-030URS-030Multi-view site display
PASS
Procedure:

Navigate to /dashboard/sites. Switch between card, table, map views.

Expected result:

All three views render correctly with site data.

Conclusion: All 30 test cases passed. Module 1 operates as specified in URS and FS.

Automated coverage: 188 E2E API tests provide continuous regression testing.

Tester: ClinicalOS QA / Automated test suite