Content-Length: 277034 | pFad | https://github.com/nodejs/node/commit/c7a132229f

C2 test: add missing test for env file · nodejs/node@c7a1322 · GitHub
Skip to content

Commit c7a1322

Browse files
JonasBaaduh95
authored andcommitted
test: add missing test for env file
PR-URL: #56642 Reviewed-By: Yagiz Nizipli <yagiz@nizipli.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com> Reviewed-By: Jake Yuesong Li <jake.yuesong@gmail.com> Reviewed-By: Matteo Collina <matteo.collina@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent a9d332a commit c7a1322

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed

test/parallel/test-dotenv-edge-cases.js

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -170,4 +170,16 @@ describe('.env supports edge cases', () => {
170170
assert.strictEqual(SingleQuotesChild.stderr, '');
171171
assert.strictEqual(SingleQuotesChild.code, 0);
172172
});
173+
174+
it('should reject invalid env file flag', async () => {
175+
const child = await common.spawnPromisified(
176+
process.execPath,
177+
['--env-file-ABCD', validEnvFilePath],
178+
{ cwd: __dirname },
179+
);
180+
181+
assert.strictEqual(child.stdout, '');
182+
assert.strictEqual(child.code, 9);
183+
assert.match(child.stderr, /bad option: --env-file-ABCD/);
184+
});
173185
});

0 commit comments

Comments
 (0)








ApplySandwichStrip

pFad - (p)hone/(F)rame/(a)nonymizer/(d)eclutterfier!      Saves Data!


--- a PPN by Garber Painting Akron. With Image Size Reduction included!

Fetched URL: https://github.com/nodejs/node/commit/c7a132229f

Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy