Development
On this page
Commands #
| Command | What it does |
|---|---|
make test | unit tests |
make e2e | builds gomagi and runs the atago specs in e2e/atago |
make lint | golangci-lint, complexity limits, architecture rules, go mod tidy -diff and go tool harai |
make coverage | coverage of the unit tests and the E2E specs together |
make mutation | gomagi on its own packages |
make demo | records the demo GIF with vhs |
make website | builds this site with Hugo |
go tool harai fails on a function no command reaches, on statements repeated elsewhere and on a test file named after no source file. AGENTS.md holds the rules of the code base.
Testing #
The README lists the testing techniques and the bugs each one catches, with links to the tests.
Third-party modules #
gomagi runs with --verify 20 on 17 pinned modules on every push to main and weekly on Linux, 14 of them on macOS and 13 on Windows (e2e/thirdparty), and 56 more were run by hand in December 2026. A module passes when gomagi finishes, every verified mutant agrees with its separate build, the clone is unchanged and no test process is left. What they found, all fixed in gomagi:
| Module | Problem | Fixed in |
|---|---|---|
| sergi/go-diff, BurntSushi/toml, golang/snappy | the rewritten package did not compile | 0.1.1 |
| spf13/cobra, go-chi/chi | tests reading os.Args[0] or a fixed port killed mutants | 0.1.1 |
| gorilla/websocket | tests failing 1 run in 30 without a mutant killed mutants | 0.1.5 |
| tidwall/pretty | a long but finite scan counted as an endless loop | 0.1.5 |
| dustin/go-humanize | --cache stored nothing when a mutant made a test panic | 0.1.5 |
| robfig/cron | suites that sleep held whole workers | 0.1.5 |
| nao1215/sqly | a rapid property’s verdict changed between runs | 0.1.7 |
| rivo/uniseg | 358 mutants were compiled one at a time | 0.1.7 |
| zeebo/xxh3, buger/jsonparser | the switched binary ran 13 to 19 times slower than the original | 0.1.7 |