Skip to content

Commit 0c2a0dc

Browse files
rsprvagg
authored andcommitted
test: skip long path tests on non-Windows
If not running on Windows it skips the long path tests in: * test-fs-long-path.js * test-require-long-path.js Fixes: #2255 PR-URL: #4116 Reviewed-By: Ben Noordhuis <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Minwoo Jung <[email protected]>
1 parent 12649f4 commit 0c2a0dc

File tree

2 files changed

+10
-0
lines changed

2 files changed

+10
-0
lines changed

test/parallel/test-fs-long-path.js

+5
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,11 @@ var fs = require('fs');
44
var path = require('path');
55
var assert = require('assert');
66

7+
if (!common.isWindows) {
8+
console.log('1..0 # Skipped: this test is Windows-specific.');
9+
return;
10+
}
11+
712
var successes = 0;
813

914
// make a path that will be at least 260 chars long.

test/parallel/test-require-long-path.js

+5
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,11 @@ const common = require('../common');
33
const fs = require('fs');
44
const path = require('path');
55

6+
if (!common.isWindows) {
7+
console.log('1..0 # Skipped: this test is Windows-specific.');
8+
return;
9+
}
10+
611
// make a path that is more than 260 chars long.
712
const dirNameLen = Math.max(260 - common.tmpDir.length, 1);
813
const dirName = path.join(common.tmpDir, 'x'.repeat(dirNameLen));

0 commit comments

Comments
 (0)