You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Most CLI's expect (TTY.isatty())[https://nodejs.org/api/tty.html#tty_tty_isatty_fd], and process.stdout.isTTY to return true. It's conceivable they will behave differently when those return false (a well designed CLI probably should).
This complicates things. Some people have tried to develop pty support for node. AVA itself fakes TTY support in forked processes here.
Both approaches have significant downsides.
pty requires native components and a build step, and so is inherently fragile for cross-platform development.
AVA's approach requires you execute code before the forked process runs. It's not a problem for AVA, since we're doing that to set up the test environment anyways, but would be harder for a general use library. Also, it only works for CLI's written in Node.
The text was updated successfully, but these errors were encountered:
Most CLI's expect (
TTY.isatty()
)[https://nodejs.org/api/tty.html#tty_tty_isatty_fd], andprocess.stdout.isTTY
to returntrue
. It's conceivable they will behave differently when those return false (a well designed CLI probably should).This complicates things. Some people have tried to develop
pty
support for node. AVA itself fakes TTY support in forked processes here.Both approaches have significant downsides.
pty
requires native components and a build step, and so is inherently fragile for cross-platform development.The text was updated successfully, but these errors were encountered: