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+
const assert = require("assert");
2+
const {
3+
promises: { stat },
4+
F_OK
5+
} = require("fs");
6+
const path = require("path");
7+
8+
describe(".env", () => {
9+
it("should have a file", async () => {
10+
const filePath = path.join(process.cwd(), ".env");
11+
const hasEnv = await stat(filePath, F_OK, err => {
12+
if (err) {
13+
console.error(err);
14+
return false;
15+
}
16+
return true;
17+
});
18+
assert.ok(hasEnv);
19+
});
20+
});

0 commit comments

Comments
 (0)