You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
 

19 lines
503 B

var Glob = require("../glob.js").Glob
var test = require('tap').test
test('globstar should not have dupe matches', function(t) {
var pattern = 'a/**/[gh]'
var g = new Glob(pattern, { cwd: __dirname })
var matches = []
g.on('match', function(m) {
console.error('match %j', m)
matches.push(m)
})
g.on('end', function(set) {
console.error('set', set)
matches = matches.sort()
set = set.sort()
t.same(matches, set, 'should have same set of matches')
t.end()
})
})