Private
Public Access
0
0

test(pytest): register clean_install marker for opt-in clone-and-verify test

This commit is contained in:
2026-06-03 00:28:20 -04:00
parent 0309420ba1
commit 573d289941
5 changed files with 63 additions and 0 deletions
@@ -0,0 +1,7 @@
# Track clean_install_test_20260603 Context
- [Specification](./spec.md)
- [Implementation Plan](./plan.md)
- [Metadata](./metadata.json)
- [Source Plan](../../../../docs/superpowers/plans/2026-06-02-clean-install-test.md)
- [Source Spec](../../../../docs/superpowers/specs/2026-06-02-clean-install-test-design.md)
@@ -0,0 +1,11 @@
{
"id": "clean_install_test_20260603",
"title": "Clean Install Test",
"phase": null,
"created": "2026-06-03",
"status": "in_progress",
"spec_file": "spec.md",
"plan_file": "plan.md",
"depends_on": [],
"completion_checkpoints": []
}
@@ -0,0 +1,22 @@
# Implementation Plan: Clean Install Test (clean_install_test_20260603)
## Phase 1: Add pytest marker
Focus: Register the `clean_install` marker in `pyproject.toml` so the test can be selected with `pytest -m clean_install` or filtered with `-m "not clean_install"`.
- [ ] Task 1.1: Pre-edit checkpoint - `git add .`
- [ ] Task 1.2: Edit `pyproject.toml` to add `clean_install` marker
- [ ] Task 1.3: Run `pytest --collect-only` to confirm marker is recognized
- [ ] Task 1.N: Atomic commit + git note
## Phase 2: Create the test file
Focus: Create `tests/test_clean_install.py` with opt-in clone-and-verify logic.
- [ ] Task 2.1: Pre-edit checkpoint - `git add .`
- [ ] Task 2.2: Create `tests/test_clean_install.py` using `urllib.request` (deviation from plan, see spec.md)
- [ ] Task 2.3: Run the test in skip mode - should be 1 skipped
- [ ] Task 2.N: Atomic commit + git note
## Phase 3: Phase Completion Verification
- [ ] Task 3.1: Run the test in default mode - should be 1 skipped (gating works)
- [ ] Task 3.2: `pytest --collect-only -m clean_install` confirms marker works
- [ ] Task 3.N: conductor(checkpoint) commit + audit note
@@ -0,0 +1,22 @@
# Clean Install Test (clean_install_test_20260603)
Opt-in pytest test that clones the Manual Slop repo to a temp dir, runs `uv sync`, launches `sloppy.py --enable-test-hooks`, and verifies the Hook API responds. Catches "works on my machine" failures by exercising the full install-and-launch path in an isolated environment.
## Goal
Add a single integration test file `tests/test_clean_install.py` that, when opted in via `RUN_CLEAN_INSTALL_TEST=1`, performs a full clean install + launch verification of Manual Slop. Skipped by default to avoid breaking CI for users without network access to the Gitea clone URL.
## Plan Source
This track executes the plan at `docs/superpowers/plans/2026-06-02-clean-install-test.md` and references the spec at `docs/superpowers/specs/2026-06-02-clean-install-test-design.md`.
## Files Touched
| File | Action |
|---|---|
| `pyproject.toml` | Modify: add `clean_install` marker |
| `tests/test_clean_install.py` | Create: opt-in clone-and-verify test |
## Deviation from Plan
The plan uses `requests` library, but `requests` is not a project dependency. Per `conductor/tech-stack.md` "Dependency Minimalism" rule and the existing pattern in `src/mcp_client.py` web tools (which use `urllib.request` + `html.parser` from stdlib), the test will use `urllib.request` from Python stdlib instead. This avoids adding a new external dependency for a single opt-in test.
+1
View File
@@ -37,6 +37,7 @@ dev = [
[tool.pytest.ini_options]
markers = [
"integration: marks tests as integration tests (requires live GUI)",
"clean_install: clean install verification (opt-in via RUN_CLEAN_INSTALL_TEST=1)",
]
[tool.mypy]