Commit 4599b6a0f27 for nodejs
commit 4599b6a0f27fa6a0bc49f93f2bc211ae7c61acf2
Author: Livia Medeiros <livia@cirno.name>
Date: Wed Oct 14 02:55:52 2026 +0800
test: skip test failing when run under root
Signed-off-by: LiviaMedeiros <livia@cirno.name>
PR-URL: https://github.com/nodejs/node/pull/66666
Reviewed-By: Xuguang Mei <meixuguang@gmail.com>
Reviewed-By: Antoine du Hamel <duhamelantoine1995@gmail.com>
Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
diff --git a/test/parallel/test-fs-rmSync-special-char-additional-error.js b/test/parallel/test-fs-rmSync-special-char-additional-error.js
index 9b4de3c84d6..51e925cdc9b 100644
--- a/test/parallel/test-fs-rmSync-special-char-additional-error.js
+++ b/test/parallel/test-fs-rmSync-special-char-additional-error.js
@@ -6,6 +6,9 @@ const fs = require('node:fs');
const path = require('node:path');
const { execSync } = require('child_process');
+if (!common.isWindows && process.getuid() === 0)
+ common.skip('running this test as root would ignore directory permissions');
+
tmpdir.refresh(); // Prepare a clean temporary directory
function countOccurrences(haystack, needle) {