mirror of
https://github.com/nodejs/node.git
synced 2025-05-17 10:27:12 +00:00

Closes: https://github.com/nodejs/node/pull/16280 PR-URL: https://github.com/nodejs/node/pull/16509 Fixes: https://github.com/nodejs/node/issues/14161 Reviewed-By: Daijiro Wachi <daijiro.wachi@gmail.com> Reviewed-By: Anna Henningsen <anna@addaleax.net> Reviewed-By: Michaël Zasso <targos@protonmail.com>
27 lines
625 B
JavaScript
27 lines
625 B
JavaScript
var test = require('tap').test
|
|
var common = require('../common-tap')
|
|
|
|
test('npm food', function (t) {
|
|
common.npm('food', {}, function (err, code, stdout, stderr) {
|
|
if (err) throw err
|
|
t.equal(code, 1, 'command ran with error')
|
|
|
|
t.has(stdout, 'Did you mean this?')
|
|
|
|
t.notOk(stderr, 'stderr should be empty')
|
|
t.end()
|
|
})
|
|
})
|
|
|
|
test('npm jet', function (t) {
|
|
common.npm('jet', {}, function (err, code, stdout, stderr) {
|
|
if (err) throw err
|
|
t.equal(code, 1, 'command ran with error')
|
|
|
|
t.has(stdout, 'Did you mean one of these?')
|
|
|
|
t.notOk(stderr, 'stderr should be empty')
|
|
t.end()
|
|
})
|
|
})
|