Skip to content

Commit

Permalink
Add async test of stat uid & gid
Browse files Browse the repository at this point in the history
(skipped on "win32" platform)
  • Loading branch information
Christopher J. Brody committed May 10, 2019
1 parent 524bdf4 commit bff7fd1
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions test/stats-uid-gid.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,16 @@ test('graceful fs includes correct uid & gid', function (t) {
t.end()
})

;(process.platform !== 'win32') && test('graceful fs includes valid uid & gid (async)', function (t) {
gfs.stat(__filename, function (er, stats) {
t.notOk(er)
t.ok(stats)
t.ok(stats.uid)
t.ok(stats.gid)
t.end()
})
})

test('does not throw when async stat fails', function (t) {
gfs.stat(__filename + ' this does not exist', function (er, stats) {
t.ok(er)
Expand Down

0 comments on commit bff7fd1

Please sign in to comment.