Files
JiboSDK/node_modules/npm/test/tap/ls-no-results.js

13 lines
368 B
JavaScript
Raw Normal View History

2026-03-22 03:21:45 +02:00
var test = require("tap").test
var spawn = require("child_process").spawn
var node = process.execPath
var npm = require.resolve("../../")
var args = [ npm, "ls", "ceci nest pas une package" ]
test("ls exits non-zero when nothing found", function (t) {
var child = spawn(node, args)
child.on("exit", function (code) {
t.notEqual(code, 0)
t.end()
})
})