1 var glob = require('../')
2 var test = require('tap').test
3 var path = require('path')
5 test('stat all the things', function(t) {
6 var g = new glob.Glob('a/*abc*/**', { stat: true, cwd: __dirname })
8 g.on('match', function(m) {
12 g.on('stat', function(m) {
15 g.on('end', function(eof) {
17 matches = matches.sort()
19 t.same(stats, matches)
21 var cache = Object.keys(this.statCache)
22 t.same(cache.map(function (f) {
23 return path.relative(__dirname, f)
26 cache.forEach(function(c) {
27 t.equal(typeof this.statCache[c], 'object')