blob: b4feb75176c4acdaf8335437e095c10fcc71640f (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
// should not allow tagging with a valid semver range
var common = require('../common-tap.js')
var test = require('tap').test
test('try to tag with semver range as tag name', function (t) {
var cmd = ['tag', 'zzzz@1.2.3', 'v2.x', '--registry=http://localhost']
common.npm(cmd, {
stdio: 'pipe'
}, function (er, code, so, se) {
if (er) throw er
t.similar(se, /Tag name must not be a valid SemVer range: v2.x\n/)
t.equal(code, 1)
t.end()
})
})
|