now has fileTree function
This commit is contained in:
12
test/test.js
12
test/test.js
File diff suppressed because one or more lines are too long
12
test/test.ts
12
test/test.ts
@ -8,8 +8,6 @@ import should = require("should");
|
||||
let vinyl = require("vinyl");
|
||||
|
||||
describe("smartfile".yellow,function(){
|
||||
|
||||
|
||||
describe(".fs".yellow,function(){
|
||||
describe(".fileExistsSync".yellow,function(){
|
||||
it("should return an accurate boolean",function(){
|
||||
@ -58,6 +56,16 @@ describe("smartfile".yellow,function(){
|
||||
});
|
||||
});
|
||||
});
|
||||
describe(".listFileTree()",function(){
|
||||
it("should get a file tree",function(done){
|
||||
smartfile.fs.listFileTree(path.resolve("./test/"),"**/*.txt")
|
||||
.then(function(folderArrayArg){
|
||||
folderArrayArg.should.containDeep([ "testfolder/testfile1.txt"]);
|
||||
folderArrayArg.should.not.containDeep([ "mytest.json"]);
|
||||
done();
|
||||
});
|
||||
});
|
||||
});
|
||||
describe(".copy()".yellow,function(){
|
||||
it("should copy a directory",function(){
|
||||
smartfile.fs.copy("./test/testfolder/","./test/temp/")
|
||||
|
Reference in New Issue
Block a user