make test no longer runs yarn build, which the frontend's unit tests do not need. This is the part of #118 that can be built now; the issue stays open.
What changed
The stage that runs the frontend's unit tests is renamed from frontend to frontend-test and no longer builds the page.
A new frontend-build stage starts from frontend-test, reusing its yarn packages and source, and runs yarn build. Like builder, it copies a file from the lint and test phases, so it cannot run unless both passed. The runtime stage copies dist/ from it.
git, which vite.config.js uses to read the commit for the footer, is installed in frontend-build instead of the test stage.
README.md, the comment in script/frontend-test and TODO.md say the same.
What a reader might trip over
In the image build, yarn build now waits for the Go tests and both linters instead of running beside them; it then runs alongside the Go compile in builder.
script/frontend-test on the host still runs the production build, because script/frontend-viewport-test uses it to make dist/.
Left for the ruling
Most of what remains of make test's time is compiling Go with the race detector from nothing. Whether a test build may keep Go's compiled packages between runs waits on sneak/prompts#113, so no build cache is added here. TODO.md lists it under Future Steps.
Judgement call: the stage rename, so the three node stages are named for what they do (frontend-lint, frontend-test, frontend-build).
Model: opus-5-5
`make test` no longer runs `yarn build`, which the frontend's unit tests do not need. This is the part of https://git.eeqj.de/sneak/netwatch/issues/118 that can be built now; the issue stays open.
**What changed**
- The stage that runs the frontend's unit tests is renamed from `frontend` to `frontend-test` and no longer builds the page.
- A new `frontend-build` stage starts from `frontend-test`, reusing its yarn packages and source, and runs `yarn build`. Like `builder`, it copies a file from the `lint` and `test` phases, so it cannot run unless both passed. The runtime stage copies `dist/` from it.
- `git`, which `vite.config.js` uses to read the commit for the footer, is installed in `frontend-build` instead of the test stage.
- `README.md`, the comment in `script/frontend-test` and `TODO.md` say the same.
**What a reader might trip over**
- In the image build, `yarn build` now waits for the Go tests and both linters instead of running beside them; it then runs alongside the Go compile in `builder`.
- `script/frontend-test` on the host still runs the production build, because `script/frontend-viewport-test` uses it to make `dist/`.
**Left for the ruling**
Most of what remains of `make test`'s time is compiling Go with the race detector from nothing. Whether a test build may keep Go's compiled packages between runs waits on https://git.eeqj.de/sneak/prompts/issues/113, so no build cache is added here. `TODO.md` lists it under Future Steps.
Judgement call: the stage rename, so the three node stages are named for what they do (`frontend-lint`, `frontend-test`, `frontend-build`).
Model: opus-5-5
PASS: make test no longer runs the production build, and the new frontend-build stage still cannot run unless the lint and test phases pass, as #118 asks of this part.
Disclosure: the branch conflicts with next only in TODO.md's Completed Steps list; I gated it rebased onto current next with both entries kept, this one on top, so it needs that rebase before merge.
Model: opus-5-5
PASS: `make test` no longer runs the production build, and the new `frontend-build` stage still cannot run unless the lint and test phases pass, as https://git.eeqj.de/sneak/netwatch/issues/118 asks of this part.
Disclosure: the branch conflicts with `next` only in `TODO.md`'s Completed Steps list; I gated it rebased onto current `next` with both entries kept, this one on top, so it needs that rebase before merge.
Model: opus-5-5
yarn build moves out of the stage that runs the frontend's unit tests,
now named frontend-test, into a frontend-build stage of its own. It
starts from frontend-test for its yarn packages and source, installs
the git that vite.config.js reads the commit with, and copies from the
lint and test phases as builder does, so it cannot run unless they
passed. The runtime stage copies dist/ from it. The Go compile, most of
make test's time, is unchanged and waits on the ruling asked for in
sneak/prompts#113; no build cache is added.
Model: opus-5-5
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
make testno longer runsyarn build, which the frontend's unit tests do not need. This is the part of #118 that can be built now; the issue stays open.What changed
frontendtofrontend-testand no longer builds the page.frontend-buildstage starts fromfrontend-test, reusing its yarn packages and source, and runsyarn build. Likebuilder, it copies a file from thelintandtestphases, so it cannot run unless both passed. The runtime stage copiesdist/from it.git, whichvite.config.jsuses to read the commit for the footer, is installed infrontend-buildinstead of the test stage.README.md, the comment inscript/frontend-testandTODO.mdsay the same.What a reader might trip over
yarn buildnow waits for the Go tests and both linters instead of running beside them; it then runs alongside the Go compile inbuilder.script/frontend-teston the host still runs the production build, becausescript/frontend-viewport-testuses it to makedist/.Left for the ruling
Most of what remains of
make test's time is compiling Go with the race detector from nothing. Whether a test build may keep Go's compiled packages between runs waits on sneak/prompts#113, so no build cache is added here.TODO.mdlists it under Future Steps.Judgement call: the stage rename, so the three node stages are named for what they do (
frontend-lint,frontend-test,frontend-build).Model: opus-5-5
PASS:
make testno longer runs the production build, and the newfrontend-buildstage still cannot run unless the lint and test phases pass, as #118 asks of this part.Disclosure: the branch conflicts with
nextonly inTODO.md's Completed Steps list; I gated it rebased onto currentnextwith both entries kept, this one on top, so it needs that rebase before merge.Model: opus-5-5
139c965beftobc150834a7