]> gerrit.simantics Code Review - simantics/district.git/blob - test/tap/bin.js
Hide "enabled" column for non-component type tech type tables
[simantics/district.git] / test / tap / bin.js
1 var path = require("path")
2 var test = require("tap").test
3 var common = require("../common-tap.js")
4 var opts = { cwd: __dirname }
5 var binDir = "../../node_modules/.bin"
6 var fixture = path.resolve(__dirname, binDir)
7
8 test('npm bin', function (t) {
9   common.npm(["bin"], opts, function (err, code, stdout, stderr) {
10     t.ifError(err, "bin ran without issue")
11     t.notOk(stderr, "should have no stderr")
12     t.equal(code, 0, "exit ok")
13     var res = path.resolve(stdout)
14     t.equal(res, fixture + "\n")
15     t.end()
16   })
17 })