cloudflare / tableflip

Graceful process restarts in Go
BSD 3-Clause "New" or "Revised" License
2.88k stars 147 forks source link

fix flaky TestFilesAreNonblocking on CI #62

Closed lmb closed 3 years ago

lmb commented 3 years ago

CI runs test with stdin closed, which leads our victim cat process to exit quickly. Depending on the ordering of events we might see the test fail. Change the contract for newOSProcess to include stdin, stdout and stderr and allocate a blocking pipe as stdin for the test.