Fix #514: add test for fsPromises.lstat with directory
Co-authored-by: David Humphrey <david.humphrey@senecacollege.ca>
This commit is contained in:
parent
848cc7d3de
commit
9a7d3514d8
|
@ -61,6 +61,14 @@ describe('fs.promises.lstat', ()=> {
|
|||
expect(error.code).to.equal('ENOENT');
|
||||
});
|
||||
});
|
||||
|
||||
it('should return a stat object if path is not a symbolic link', () => {
|
||||
var fsPromises = util.fs().promises;
|
||||
|
||||
return fsPromises.lstat('/')
|
||||
.then(result => {
|
||||
expect(result).to.exist;
|
||||
expect(result.isDirectory()).to.be.true;
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue