Skip to content

Commit

Permalink
test: compare paths on Windows without considering case
Browse files Browse the repository at this point in the history
PR-URL: #53993
Fixes: #53989
Reviewed-By: James M Snell <[email protected]>
Reviewed-By: Luigi Pinca <[email protected]>
Reviewed-By: Daeyeon Jeong <[email protected]>
Reviewed-By: Yagiz Nizipli <[email protected]>
Reviewed-By: Stefan Stojanovic <[email protected]>
Reviewed-By: Antoine du Hamel <[email protected]>
  • Loading branch information
EarlyRiser42 authored and marco-ippolito committed Aug 19, 2024
1 parent 490f15a commit f2b4fd3
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion test/parallel/test-child-process-cwd.js
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,14 @@ function testCwd(options, expectPidType, expectCode = 0, expectData) {
});

child.on('close', common.mustCall(function() {
expectData && assert.strictEqual(data.trim(), expectData);
if (expectData) {
// In Windows, compare without considering case
if (common.isWindows) {
assert.strictEqual(data.trim().toLowerCase(), expectData.toLowerCase());
} else {
assert.strictEqual(data.trim(), expectData);
}
}
}));

return child;
Expand Down

0 comments on commit f2b4fd3

Please sign in to comment.