Skip to content

Commit

Permalink
test: do not write to fixtures dir in test-watch-file
Browse files Browse the repository at this point in the history
Switch to tmpDir rather than fixtures for file writing.

PR-URL: #34376
Reviewed-By: Richard Lau <riclau@uk.ibm.com>
Reviewed-By: James M Snell <jasnell@gmail.com>
  • Loading branch information
Trott authored and MylesBorins committed Jul 27, 2020
1 parent 699da05 commit 77542a4
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions test/pummel/test-watch-file.js
Expand Up @@ -24,9 +24,12 @@
require('../common');
const assert = require('assert');
const fs = require('fs');
const fixtures = require('../common/fixtures');
const path = require('path');
const tmpdir = require('../common/tmpdir');

const f = fixtures.path('x.txt');
tmpdir.refresh();
const f = path.join(tmpdir.path, 'x.txt');
fs.closeSync(fs.openSync(f, 'w'));

let changes = 0;
function watchFile() {
Expand Down

0 comments on commit 77542a4

Please sign in to comment.