From a5ada418c43b27c684af2d558795ee4b76c622ad Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Thu, 21 Dec 2017 14:38:02 -0800 Subject: [PATCH] test: do not open fixture files for writing test-fs-fsync makes a copy of a fixture file, but then doesn't do anything with it and instead operates on the original fixture file. This appears to be in error, and this change fixes that. PR-URL: https://github.com/nodejs/node/pull/17808 Reviewed-By: Jon Moss Reviewed-By: Colin Ihrig Reviewed-By: Richard Lau Reviewed-By: Ruben Bridgewater Reviewed-By: Gireesh Punathil Reviewed-By: James M Snell --- test/parallel/test-fs-fsync.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/parallel/test-fs-fsync.js b/test/parallel/test-fs-fsync.js index 3f43dd75450517..c55056e501f648 100644 --- a/test/parallel/test-fs-fsync.js +++ b/test/parallel/test-fs-fsync.js @@ -34,7 +34,7 @@ const fileTemp = path.join(common.tmpDir, 'a.js'); common.refreshTmpDir(); fs.copyFileSync(fileFixture, fileTemp); -fs.open(fileFixture, 'a', 0o777, common.mustCall(function(err, fd) { +fs.open(fileTemp, 'a', 0o777, common.mustCall(function(err, fd) { assert.ifError(err); fs.fdatasyncSync(fd);