no caching in test containers

This commit is contained in:
2026-09-05 21:55:29 +02:00
parent 055d8a9620
commit 0e2d4030bd
7 changed files with 67 additions and 36 deletions
+10 -15
View File
@@ -140,14 +140,14 @@ There are **two tiers**:
| `make test-stow` | `stow --simulate` for every stow-able package; fails if a package the Makefile stows doesn't exist (e.g. `stow nvim` — nvim lives under `term/`). | No |
| `make test-shellcheck` | Runs shellcheck over all tracked scripts (shellcheck must be installed). | No |
| `make test-lint-docker` | Builds the `/dev` stage (`archlinux:latest` + shellcheck) and runs `test/lint.sh` inside it. | Yes |
| `make test-smoke` | Builds the `/test` stage and runs the container's dry probes: `make -n` over every target, `stow --simulate` over every Makefile-stowed package, plus `test/lint.sh`. A network-enabled `RUN_SMOKE=1` variant installs the real pacman packages. | Yes |
| `make test` | `test-lint` + `test-smoke`. | Partially |
| `make test-smoke` | Builds the `/test` stage, runs the container's dry probes (`make -n` over every target, `stow --simulate` over every Makefile-stowed package, `test/lint.sh`), **and by default installs the real pacman packages** (`REAL_SMOKE=1`) then verifies them. | Yes |
| `make test` | `test-lint` + `test-smoke` (the real install runs). | Partially |
### Docker smoke details
```bash
make test-smoke # dry probes only (fast, no installs)
make test-smoke RUN_SMOKE=1 # + real pacman installs of the term packages
make test-smoke # real pacman install of the term packages + verify
make test-smoke REAL_SMOKE=0 # dry probes only (fast, no installs)
make test-smoke RUN_SMOKE=1 RUN_FULL=1 # + AUR/npm + hypr/kreation/buntes-monster
make test-smoke SKIP_NET=1 # skip anything that contacts the network
```
@@ -159,24 +159,19 @@ The container:
scripts don't hang on a password prompt,
- mounts the live repo at `/dotfiles` (`-v "$PWD":/dotfiles`), so the tests
always run against your current checkout,
- stubs host daemon commands (`systemctl`, `updatedb`, `kbuildsycoca6`,
`dbus-update-activation-environment`) as no-ops so nothing talks to a real
systemd/dbus inside the container.
- stubs host-dependent commands as no-ops so nothing talks to a real systemd/dbus
inside the container (`systemctl`, `updatedb`, `kbuildsycoca6`,
`dbus-update-activation-environment`, `chsh`), and routes `yay` through
`pacman` for the pacman-only smoke.
In the `RUN_SMOKE=1` install path, the harness additionally **verifies the
installed packages** (`test/verify_packages.sh`):
In the `REAL_SMOKE=1` (default) install path, the harness additionally
**verifies the installed packages** (`test/verify_packages.sh`):
- every `@pacman` entry is confirmed via `pacman -Q <pkg>` (covers fonts,
libs and python modules that ship no binary),
- a curated mapping probes each package's binary with a real
`--version`-style call (e.g. `fish --version`, `nvim --version`,
`ssh -V`), failing if the binary is missing or does not report a version.
> **Note for the current repo state:** `make test-lint` and `make test-smoke`
> currently **fail** because the harness surfaces pre-existing Makefile bugs
> (missing `/` in the `install_*` script paths and `stow nvim` for a
> non-existent `nvim/` package). That is the intended behaviour — fix the
> Makefile and the tests should go green.
---
**When in doubt:** run `stow --verbose --simulate <target>` first — it prints what would happen (linking) without changing anything. Never `rm -rf` the `~/.config` of something you still want to keep; move it to a backup directory instead.