Bläddra i källkod

Add contract/test example to test plan template

main
Nano 3 timmar sedan
förälder
incheckning
5247e4dd57
1 ändrade filer med 21 tillägg och 0 borttagningar
  1. +21
    -0
      .ai/templates/test-plan.md

+ 21
- 0
.ai/templates/test-plan.md Visa fil

@@ -26,6 +26,27 @@
- [ ] Failure modes are covered.
- [ ] Postconditions are observable.

## Example

Feature: Export a territory

Contract under test:

- Preconditions: The territory exists and the user is authorized.
- Inputs: Territory ID.
- Outputs: A downloadable ZIP file.
- Postconditions: The ZIP contains the generated XLSX and PDFs.
- Invariants: The exported files are named consistently.
- Failure modes: Missing territory, file write failure, or export timeout.
- Side effects: Temporary export files may be created and cleaned up after download.

Test focus:

- Verify the export is rejected when the territory is missing.
- Verify the ZIP contains both the spreadsheet and the PDFs.
- Verify failed file writes are reported as errors.
- Verify cleanup happens after download.

---

## Self-Evolution Protocol


Laddar…
Avbryt
Spara

Powered by TurnKey Linux.