Here's an example of the build step: https://github.com/multiprocessio/datastation/blob/main/runn....
And here's how I'd analyze coverage after using the binary: https://github.com/multiprocessio/datastation/blob/main/runn.... This analysis actually combined both unit test coverage files with integration test coverage so it gave a pretty good overall indication of code paths covered by any tests.
I can't remember where I found this technique but it's been around for a while.
This new option is the same thing but a way to `go build` with `-cover` instead of `go test -cover -o $out`? Do I have that right?
Another example of doing this from 2019: https://stackoverflow.com/a/55640874/1507139. I'm sure I learned about this from somebody's blog but I can't remember where.