elvish/pkg/prog
Kurtis Rader fbd86925a9 Prevent I/O deadlocks during shell testing
If the shell outputs more data than can be buffered the test will
deadlock. I noticed this when working on issue #661. The tests I was
writing would deadlock because a tty can buffer significantly less data
than a pipe. Even using a pipe, which typically buffers 8 to 128 KiB, this
is theoretically a problem. So use a goroutine to capture the output as it
is generated rather than reading it all at once when the test terminates.
2020-08-11 15:58:20 +01:00
..
progtest Prevent I/O deadlocks during shell testing 2020-08-11 15:58:20 +01:00
prog_test.go Verify stdout and stderr in shell tests 2020-08-11 15:58:20 +01:00
prog.go Suppress deprecations by default. 2020-04-26 21:26:53 +01:00