Allow tests to fake stdin/stdout/stderr is a console
We've been unable to effectively test cases where stdin/stdout/stderr
are consoles, because in our test cases they generally aren't. Allow the
command line flags `--fake-std{in,out,err}-is-console` to tell the CLI
to pretend that std{in,out,err} is a console.
This commit is contained in:
committed by
Nick Terrell
parent
031de3c69c
commit
e58a39f84e
@@ -127,6 +127,10 @@ extern "C" {
|
||||
|
||||
/*-*********************************************
|
||||
* Detect if isatty() and fileno() are available
|
||||
*
|
||||
* Note: Use UTIL_isConsole() for the zstd CLI
|
||||
* instead, as it allows faking is console for
|
||||
* testing.
|
||||
************************************************/
|
||||
#if (defined(__linux__) && (PLATFORM_POSIX_VERSION > 1)) \
|
||||
|| (PLATFORM_POSIX_VERSION >= 200112L) \
|
||||
|
||||
Reference in New Issue
Block a user