Related, I gave a 6 minute lightning talk about writing tests in Go that use the test binary itself as the PID 1 under an emulated Linux in QEMU:
https://docs.google.com/presentation/d/1rAAyOTCsB8GLbMgI0CAb...
https://www.youtube.com/watch?v=69Zy77O-BUM