Skip to content

Commit bee85b1

Browse files
test: add offline regression harness for archive runner (#1)
* test: add offline runner regression harness * docs: document offline runner regression tests * ci: run offline runner regression tests * ci: update GitHub Actions runtime versions
1 parent 1b9216d commit bee85b1

3 files changed

Lines changed: 475 additions & 1 deletion

File tree

Lines changed: 29 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,29 @@
1+
name: Offline runner regression tests
2+
3+
on:
4+
push:
5+
pull_request:
6+
7+
permissions:
8+
contents: read
9+
10+
jobs:
11+
unittest:
12+
runs-on: ubuntu-latest
13+
timeout-minutes: 5
14+
strategy:
15+
fail-fast: false
16+
matrix:
17+
python-version: ["3.9", "3.11"]
18+
19+
steps:
20+
- name: Check out repository
21+
uses: actions/checkout@v7
22+
23+
- name: Set up Python ${{ matrix.python-version }}
24+
uses: actions/setup-python@v7
25+
with:
26+
python-version: ${{ matrix.python-version }}
27+
28+
- name: Run offline runner regression tests
29+
run: python -m unittest discover -s tests -p "test_*.py" -v

README.md

Lines changed: 15 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,9 @@ Place this repository directly inside the initialized Moonshine runtime home, no
3232
├── README.md
3333
├── run_archive.py
3434
├── archive-format-specification.md
35-
├── skills/
35+
├── tests/
36+
│ └── test_run_archive_offline.py
37+
├── skills/
3638
│ ├── math-object-origin-archive/
3739
│ │ └── SKILL.md
3840
│ └── verify-math-object-origin-archive/
@@ -107,3 +109,15 @@ The following directories are created automatically when the runner is used and
107109

108110
- Final archives: `Creative-Intelligence/archives/<input-name>/`
109111
- Queue state and project/session associations: `Creative-Intelligence/runs/<input-name>.state.json`
112+
113+
## Offline regression tests
114+
115+
The deterministic runner contracts can be tested from a standalone checkout without an initialized Moonshine runtime, provider credentials, network access, or model calls. The test harness uses only the Python standard library and provides import-time stubs for the narrow Moonshine symbols required to load `run_archive.py`.
116+
117+
Run from the `Creative-Intelligence` repository root:
118+
119+
```bash
120+
python -m unittest discover -s tests -p "test_*.py" -v
121+
```
122+
123+
These tests cover runner-owned deterministic behavior such as queue validation, immutable queue state, format-placeholder checks, verifier-output integrity, archive overwrite protection, and provider preflight logic. They do **not** simulate Moonshine agent execution, session storage, MCP tools, or real verification-provider behavior; those remain runtime integration concerns.

0 commit comments

Comments
 (0)