Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit a6f786d

Browse filesBrowse files
saurabhSiddhuMylesBorins
authored andcommitted
test: replacing fixture directory with temp
PR-URL: #24077 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: James M Snell <jasnell@gmail.com>
1 parent 6ce4ef3 commit a6f786d
Copy full SHA for a6f786d

File tree

Expand file treeCollapse file tree

1 file changed

+12
-5
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+12
-5
lines changed
Open diff view settings
Collapse file

‎test/parallel/test-fs-error-messages.js‎

Copy file name to clipboardExpand all lines: test/parallel/test-fs-error-messages.js
+12-5Lines changed: 12 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,15 +25,22 @@ const fixtures = require('../common/fixtures');
2525
const tmpdir = require('../common/tmpdir');
2626
const assert = require('assert');
2727
const fs = require('fs');
28+
const path = require('path');
2829

2930
tmpdir.refresh();
3031

31-
const nonexistentFile = fixtures.path('non-existent');
32-
const nonexistentDir = fixtures.path('non-existent', 'foo', 'bar');
33-
const existingFile = fixtures.path('exit.js');
34-
const existingFile2 = fixtures.path('a.js');
35-
const existingDir = tmpdir.path;
32+
33+
const nonexistentFile = path.join(tmpdir.path, 'non-existent');
34+
const nonexistentDir = path.join(tmpdir.path, 'non-existent', 'foo', 'bar');
35+
const existingFile = path.join(tmpdir.path, 'existingFile.js');
36+
const existingFile2 = path.join(tmpdir.path, 'existingFile2.js');
37+
const existingDir = path.join(tmpdir.path, 'dir');
3638
const existingDir2 = fixtures.path('keys');
39+
fs.mkdirSync(existingDir);
40+
fs.writeFileSync(existingFile, 'test', 'utf-8');
41+
fs.writeFileSync(existingFile2, 'test', 'utf-8');
42+
43+
3744
const { COPYFILE_EXCL } = fs.constants;
3845
const uv = process.binding('uv');
3946

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.