]> gerrit.simantics Code Review - simantics/district.git/blob - org.simantics.maps.server/node/node-v4.8.0-win-x64/node_modules/npm/test/tap/invalid-cmd-exit-code.js
Adding integrated tile server
[simantics/district.git] / org.simantics.maps.server / node / node-v4.8.0-win-x64 / node_modules / npm / test / tap / invalid-cmd-exit-code.js
1 var test = require("tap").test
2 var common = require("../common-tap.js")
3
4 var opts = { cwd: process.cwd() }
5
6 test("npm asdf should return exit code 1", function (t) {
7   common.npm(["asdf"], opts, function (er, c) {
8     if (er) throw er
9     t.ok(c, "exit code should not be zero")
10     t.end()
11   })
12 })
13
14 test("npm help should return exit code 0", function (t) {
15   common.npm(["help"], opts, function (er, c) {
16     if (er) throw er
17     t.equal(c, 0, "exit code should be 0")
18     t.end()
19   })
20 })
21
22 test("npm help fadf should return exit code 0", function (t) {
23   common.npm(["help", "fadf"], opts, function (er, c) {
24     if (er) throw er
25     t.equal(c, 0, "exit code should be 0")
26     t.end()
27   })
28 })