docs: Update core documentation with Structural Testing Contract
This commit is contained in:
@@ -212,6 +212,12 @@ Before marking any task complete, verify:
|
||||
|
||||
## Testing Requirements
|
||||
|
||||
### Structural Testing Contract
|
||||
|
||||
1. **Ban on Arbitrary Core Mocking:** Tier 3 workers are strictly forbidden from using `unittest.mock.patch` to bypass or stub core infrastructure (e.g., event queues, `ai_client` internals, threading primitives) unless explicitly authorized by the Tier 2 Tech Lead for a specific boundary test.
|
||||
2. **`live_gui` Standard:** All integration and end-to-end testing must utilize the `live_gui` fixture to interact with a real instance of the application via the Hook API. Bypassing the hook server to directly mutate GUI state in tests is prohibited.
|
||||
3. **Artifact Isolation:** All test-generated artifacts (logs, temporary workspaces, mock outputs) MUST be written to the `tests/artifacts/` or `tests/logs/` directories. These directories are git-ignored to prevent repository pollution.
|
||||
|
||||
### Unit Testing
|
||||
|
||||
- Every module must have corresponding tests.
|
||||
|
||||
Reference in New Issue
Block a user