Files
automaton/memory/testing-conventions.md
T

13 lines
920 B
Markdown
Raw Normal View History

# Testing conventions for automaton framework
- Test suite: `python3 -m pytest tests/ -v` (249 tests as of audit completion)
- Tests call status.py via subprocess: `_run_status(["--flag", "val"], project)` pattern in test_status.py
- `_create_task(project, task_name, phase)` helper creates task via `--create-task` and writes `.state` file
- `tmp_project` fixture creates `.automaton/tasks/` structure in tmp_path
- Dashboard tests in test_app.py use `_make_task()` helper and `determine_task_state()` directly
- When changing phase mappings (e.g. TEST_PLAN.md → test_design), update BOTH status.py tests AND test_task.py tests
- vram_detect tests import module directly: `import vram_detect as vram`
- Framework self-consistency tests in test_prompt_paths.py verify canonical task paths in prompts
- Compile check: `python3 -m py_compile automaton/**/*.py scripts/*.py`
- Shell syntax check: `bash -n scripts/*.sh`