From 19e06d71cfa26b6f8a1ce0fa566891553eb351b2 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C5=82=20Pocztarski?= Date: Wed, 2 Dec 2015 18:13:27 +0100 Subject: [PATCH] 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: https://github.com/nodejs/node/issues/2255 PR-URL: https://github.com/nodejs/node/pull/4116 Reviewed-By: Ben Noordhuis Reviewed-By: James M Snell Reviewed-By: Minwoo Jung --- test/parallel/test-fs-long-path.js | 5 +++++ test/parallel/test-require-long-path.js | 5 +++++ 2 files changed, 10 insertions(+) diff --git a/test/parallel/test-fs-long-path.js b/test/parallel/test-fs-long-path.js index 6ecf549029..eadbcd1f78 100644 --- a/test/parallel/test-fs-long-path.js +++ b/test/parallel/test-fs-long-path.js @@ -4,6 +4,11 @@ var fs = require('fs'); var path = require('path'); var assert = require('assert'); +if (!common.isWindows) { + console.log('1..0 # Skipped: this test is Windows-specific.'); + return; +} + var successes = 0; // make a path that will be at least 260 chars long. diff --git a/test/parallel/test-require-long-path.js b/test/parallel/test-require-long-path.js index 1f7e28cba2..c30a76a5a9 100644 --- a/test/parallel/test-require-long-path.js +++ b/test/parallel/test-require-long-path.js @@ -3,6 +3,11 @@ const common = require('../common'); const fs = require('fs'); const path = require('path'); +if (!common.isWindows) { + console.log('1..0 # Skipped: this test is Windows-specific.'); + return; +} + // make a path that is more than 260 chars long. const dirNameLen = Math.max(260 - common.tmpDir.length, 1); const dirName = path.join(common.tmpDir, 'x'.repeat(dirNameLen));