Skip to content

Commit eaf4220

Browse files
committed
6.1 create .env
1 parent 2f1db3c commit eaf4220

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

test/env.test.js

+20
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
constassert=require("assert");
2+
const{
3+
promises: { stat },
4+
F_OK
5+
}=require("fs");
6+
constpath=require("path");
7+
8+
describe(".env",()=>{
9+
it("should have a file",async()=>{
10+
constfilePath=path.join(process.cwd(),".env");
11+
consthasEnv=awaitstat(filePath,F_OK,err=>{
12+
if(err){
13+
console.error(err);
14+
returnfalse;
15+
}
16+
returntrue;
17+
});
18+
assert.ok(hasEnv);
19+
});
20+
});

0 commit comments

Comments
 (0)
close