diff options
Diffstat (limited to 'deps/node/deps/node-inspect/test/cli/help.test.js')
-rw-r--r-- | deps/node/deps/node-inspect/test/cli/help.test.js | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/deps/node/deps/node-inspect/test/cli/help.test.js b/deps/node/deps/node-inspect/test/cli/help.test.js new file mode 100644 index 00000000..9f0c081b --- /dev/null +++ b/deps/node/deps/node-inspect/test/cli/help.test.js @@ -0,0 +1,22 @@ +'use strict'; +const { test } = require('tap'); + +const startCLI = require('./start-cli'); + +test('examples/empty.js', (t) => { + const cli = startCLI(['examples/empty.js']); + + function onFatal(error) { + cli.quit(); + throw error; + } + + return cli.waitForInitialBreak() + .then(() => cli.waitForPrompt()) + .then(() => cli.command('help')) + .then(() => { + t.match(cli.output, /run, restart, r\s+/m); + }) + .then(() => cli.quit()) + .then(null, onFatal); +}); |