# Test Plan | Field | Value | |-----------------|--------------------------------------| | Project | demo-epb | | Date | 2026-05-11 | | Version | 1.0 | | Status | Released | --- ## 1. Test strategy Test-first for all demo components. Every requirement has at least one test (`@reqs` tag in the test). Coverage targets as in the SWE Plan section 8. ## 2. Test levels | Level | Scope | Tool | Environment | Demo status | |---------------|--------------------|------------|-------------|---------------| | Unit | Functions / modules| CppUTest | host x86 | Available | | Integration | Module interaction | CppUTest | host x86 | TBD | | System | End-to-end | manual | SiL / HiL | not in demo | | Acceptance | Customer acceptance| manual | HiL / vehicle | not in demo | ## 3. Test management - Tests live in `tests/unit/` (one file per module) - Each test file carries an `@reqs` tag with the covered requirement IDs - Tests run automatically in CI on every push - Coverage report is uploaded as a CI artefact under `tests/results/coverage/` ## 4. Test selection per component | Component | ASIL | Test file | Method | |--------------------|------|---------------------------------------|---------------------------------| | Apply Controller | D | tests/unit/test_apply_controller.c | Equivalence classes + boundary + MC/DC | | Actuator Driver | B | tests/unit/test_actuator_driver.c | Equivalence classes + boundary | | Switch Debouncer | QM | tests/unit/test_switch_debouncer.c | Equivalence classes | ## 5. Entry and exit criteria **Entry to test execution:** - Code compiles - Doorstop check is green - Static analysis has no critical findings **Exit:** - All tests green - Coverage target reached - Test report archived ## 6. Defect handling - Test failure = blocking issue - Issue is filed via Gitea Issues, referenced in the PR - Severity classification per QA Plan section 4 ## 7. Reporting Test reports are generated automatically: - Console output of CppUTest (TAP / JUnit XML) - Coverage HTML from lcov - Both as CI artefacts under `tests/results/`