mirror of https://github.com/pulumi/pulumi.git
![]() Some tests were writing directly to os.Stdout, causing noise for other tests. For `TestRunWithOutputDoesNotMissData` we don't need to write anything, we only need a slow writer. For `TestNonblockingStdout` we need to more carefully emulate the behaviour seen with os.Stdout. We can do this using a named pipe initially opened from Go without O_NONBLOCK. This ensures that Go thinks this file descriptor is blocking and does not add the file to its internal poller that handles non-blocking IO. As previously, we then trick Go by changing the file to be non-blocking behind its back and trigger the bug. --------- Co-authored-by: Fraser Waters <fraser@pulumi.com> |
||
---|---|---|
.. | ||
testdata | ||
go.mod | ||
go.sum | ||
language_test.go | ||
main.go | ||
main_test.go | ||
proxy.go | ||
proxy_unix.go | ||
proxy_windows.go |