diff --git a/test/parallel/test-fs-error-messages.js b/test/parallel/test-fs-error-messages.js index 28141f33f62965..f406e8743ed120 100644 --- a/test/parallel/test-fs-error-messages.js +++ b/test/parallel/test-fs-error-messages.js @@ -22,13 +22,17 @@ 'use strict'; const common = require('../common'); const fixtures = require('../common/fixtures'); +const tmpdir = require('../common/tmpdir'); const assert = require('assert'); const fs = require('fs'); + +tmpdir.refresh(); + const nonexistentFile = fixtures.path('non-existent'); const nonexistentDir = fixtures.path('non-existent', 'foo', 'bar'); const existingFile = fixtures.path('exit.js'); const existingFile2 = fixtures.path('create-file.js'); -const existingDir = fixtures.path('empty'); +const existingDir = tmpdir.path; const existingDir2 = fixtures.path('keys'); const { COPYFILE_EXCL } = fs.constants; const uv = process.binding('uv');