Skip to content

Commit d6ef46d

Browse files
committed
test: skip the namespace case on Windows
Windows resolves the dangling link in that setup differently and skips the entry, which predates this change. The /var against /private/var divergence the test covers is a POSIX shape, and macOS and Linux still exercise it.
1 parent 0039152 commit d6ef46d

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎test/tar/symlink-resolution.test.js‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -233,7 +233,13 @@ describe('test/tar/symlink-resolution.test.js', () => {
233233
// destDir is given as linkBase/dest while its real path is realBase/dest, the
234234
// shape /var -> /private/var produces on macOS. A link target written in the
235235
// real namespace must still be recognised as living inside destDir.
236-
it('should accept a dangling target written in the real namespace', async () => {
236+
//
237+
// Skipped on Windows, where a dangling link resolves differently and the entry
238+
// is skipped regardless. That behaviour predates this change, and the namespace
239+
// divergence covered here is a POSIX shape.
240+
const itPosix = process.platform === 'win32' ? it.skip : it;
241+
242+
itPosix('should accept a dangling target written in the real namespace', async () => {
237243
const realBase = path.join(tempDir, 'realBase');
238244
const linkBase = path.join(tempDir, 'linkBase');
239245
fs.mkdirSync(path.join(realBase, 'dest'), { recursive: true });

0 commit comments

Comments
 (0)