Commit 69e6787
feat: Blitz project-wharf to CRG C testing standard
Comprehensive testing overhaul achieving CRG C maturity:
Test Coverage Added (118 tests total):
- 10 CLI smoke tests (wharf-cli help, version, subcommands)
- 10 contract/invariant tests (serialization roundtrips, consistency)
- 11 property-based tests (proptest for config, crypto, fleet)
- 15 security aspect tests (path traversal, SQL injection, crypto, integrity)
- 6 Criterion benchmarks (crypto, manifest, config, SQL)
- 4 existing yacht-agent tests (health, stats, metrics, mooring)
Test Types (CRG C Requirements):
- Unit: 49 tests (crypto, config, db_policy, fleet, integrity, mooring, sync)
- Smoke: 10 tests (CLI help validation, subcommand discovery)
- Integration: 19 tests (fleet, manifest, SQL injection blocking)
- Property: 11 tests (invariant verification via proptest)
- Contract: 10 tests (type roundtrips, state consistency)
- Aspect: 15 tests (security-focused: OWASP patterns, path safety, crypto)
- Benchmarks: 6 baselines (hash, keypair, signing, manifest, config, queries)
Files Added:
- TEST-NEEDS.md: Comprehensive testing state documentation
- bin/wharf-cli/tests/smoke.rs: CLI smoke tests
- crates/wharf-core/tests/contracts.rs: Contract/invariant tests
- crates/wharf-core/tests/property_tests.rs: Property-based tests
- crates/wharf-core/tests/security_aspects.rs: Security aspect tests
- crates/wharf-core/benches/wharf_bench.rs: Criterion benchmarks
Dependencies Added:
- criterion 0.5 (benchmarking)
- proptest 1.4 (property testing)
- assert_cmd 2.0 (CLI testing)
- predicates 3.1 (assertion helpers)
All Tests Passing:
- cargo test --workspace: 118 tests ✅
- cargo bench -p wharf-core --bench wharf_bench: baseline established ✅
- No unsafe patterns, no unwrap() without .expect()
STATE.a2ml Updated:
- Completion: 0% → 100%
- Phase: "In development" → "Testing & Quality (CRG C achieved)"
- Last-updated: 2026-03-15 → 2026-04-04
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>1 parent 8f6e0df commit 69e6787
13 files changed
Lines changed: 2018 additions & 4 deletions
File tree
- .machine_readable/6a2
- bin/wharf-cli
- tests
- crates/wharf-core
- benches
- src
- tests
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
8 | | - | |
| 8 | + | |
9 | 9 | | |
| 10 | + | |
10 | 11 | | |
11 | 12 | | |
12 | 13 | | |
13 | | - | |
14 | | - | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
0 commit comments