Skip to content

Commit 2eea850

Browse files
danielbayleymarco-ippolito
authored andcommitted
src,test: further cleanup references to osx
PR-URL: #53820 Reviewed-By: Antoine du Hamel <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: Luigi Pinca <[email protected]> Reviewed-By: Rafael Gonzaga <[email protected]>
1 parent e352a4e commit 2eea850

36 files changed

+48
-48
lines changed

Makefile

+1-1
Original file line numberDiff line numberDiff line change
@@ -1003,7 +1003,7 @@ else
10031003
BINARYNAME=$(TARNAME)-$(PLATFORM)-$(ARCH)
10041004
endif
10051005
BINARYTAR=$(BINARYNAME).tar
1006-
# OSX doesn't have xz installed by default, http://macpkg.sourceforge.net/
1006+
# macOS doesn't have xz installed by default, http://macpkg.sourceforge.net/
10071007
HAS_XZ ?= $(shell command -v xz > /dev/null 2>&1; [ $$? -eq 0 ] && echo 1 || echo 0)
10081008
# Supply SKIP_XZ=1 to explicitly skip .tar.xz creation
10091009
SKIP_XZ ?= 0

configure.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -163,14 +163,14 @@
163163
dest="fully_static",
164164
default=None,
165165
help="Generate an executable without external dynamic libraries. This "
166-
"will not work on OSX when using the default compilation environment")
166+
"will not work on macOS when using the default compilation environment")
167167

168168
parser.add_argument("--partly-static",
169169
action="store_true",
170170
dest="partly_static",
171171
default=None,
172172
help="Generate an executable with libgcc and libstdc++ libraries. This "
173-
"will not work on OSX when using the default compilation environment")
173+
"will not work on macOS when using the default compilation environment")
174174

175175
parser.add_argument("--enable-vtune-profiling",
176176
action="store_true",
@@ -1682,7 +1682,7 @@ def without_ssl_error(option):
16821682
def configure_static(o):
16831683
if options.fully_static or options.partly_static:
16841684
if flavor == 'mac':
1685-
warn("Generation of static executable will not work on OSX "
1685+
warn("Generation of static executable will not work on macOS "
16861686
"when using the default compilation environment")
16871687
return
16881688

node.gypi

+1-1
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@
217217
}],
218218

219219
[ 'OS=="mac"', {
220-
# linking Corefoundation is needed since certain OSX debugging tools
220+
# linking Corefoundation is needed since certain macOS debugging tools
221221
# like Instruments require it for some features
222222
'libraries': [ '-framework CoreFoundation' ],
223223
'defines!': [

src/large_pages/node_large_page.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@
4848
// To move the .text section, perform the following steps:
4949
// * Map a new, temporary area and copy the original code there.
5050
// * Use mmap using the start address with MAP_FIXED so we get exactly the
51-
// same virtual address (except on OSX). On platforms other than Linux,
51+
// same virtual address (except on macOS). On platforms other than Linux,
5252
// use mmap flags to request hugepages.
5353
// * On Linux use madvise with MADV_HUGEPAGE to use anonymous 2MB pages.
5454
// * If successful copy the code to the newly mapped area and protect it to

src/node_internals.h

+1-1
Original file line numberDiff line numberDiff line change
@@ -363,7 +363,7 @@ bool HasSignalJSHandler(int signum);
363363

364364
#ifdef _WIN32
365365
typedef SYSTEMTIME TIME_TYPE;
366-
#else // UNIX, OSX
366+
#else // UNIX, macOS
367367
typedef struct tm TIME_TYPE;
368368
#endif
369369

src/node_report.cc

+1-1
Original file line numberDiff line numberDiff line change
@@ -133,7 +133,7 @@ static void WriteNodeReport(Isolate* isolate,
133133
tm_struct.wMinute,
134134
tm_struct.wSecond);
135135
writer.json_keyvalue("dumpEventTime", timebuf);
136-
#else // UNIX, OSX
136+
#else // UNIX, macOS
137137
snprintf(timebuf,
138138
sizeof(timebuf),
139139
"%4d-%02d-%02dT%02d:%02d:%02dZ",

src/util.cc

+2-2
Original file line numberDiff line numberDiff line change
@@ -316,7 +316,7 @@ std::vector<char> ReadFileSync(FILE* fp) {
316316
void DiagnosticFilename::LocalTime(TIME_TYPE* tm_struct) {
317317
#ifdef _WIN32
318318
GetLocalTime(tm_struct);
319-
#else // UNIX, OSX
319+
#else // UNIX, macOS
320320
struct timeval time_val;
321321
gettimeofday(&time_val, nullptr);
322322
localtime_r(&time_val.tv_sec, tm_struct);
@@ -339,7 +339,7 @@ std::string DiagnosticFilename::MakeFilename(
339339
oss << "." << std::setfill('0') << std::setw(2) << tm_struct.wHour;
340340
oss << std::setfill('0') << std::setw(2) << tm_struct.wMinute;
341341
oss << std::setfill('0') << std::setw(2) << tm_struct.wSecond;
342-
#else // UNIX, OSX
342+
#else // UNIX, macOS
343343
oss << "."
344344
<< std::setfill('0')
345345
<< std::setw(4)

test/common/README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ Platform check for Linux.
282282

283283
Platform check for Linux on PowerPC.
284284

285-
### `isOSX`
285+
### `isMacOS`
286286

287287
* [\<boolean>][<boolean>]
288288

test/common/index.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -141,7 +141,7 @@ const isSunOS = process.platform === 'sunos';
141141
const isFreeBSD = process.platform === 'freebsd';
142142
const isOpenBSD = process.platform === 'openbsd';
143143
const isLinux = process.platform === 'linux';
144-
const isOSX = process.platform === 'darwin';
144+
const isMacOS = process.platform === 'darwin';
145145
const isASan = process.config.variables.asan === 1;
146146
const isPi = (() => {
147147
try {
@@ -981,7 +981,7 @@ const common = {
981981
isLinux,
982982
isMainThread,
983983
isOpenBSD,
984-
isOSX,
984+
isMacOS,
985985
isPi,
986986
isSunOS,
987987
isWindows,

test/common/index.mjs

+2-2
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const {
3030
isLinuxPPCBE,
3131
isMainThread,
3232
isOpenBSD,
33-
isOSX,
33+
isMacOS,
3434
isSunOS,
3535
isWindows,
3636
localIPv6Hosts,
@@ -85,7 +85,7 @@ export {
8585
isLinuxPPCBE,
8686
isMainThread,
8787
isOpenBSD,
88-
isOSX,
88+
isMacOS,
8989
isSunOS,
9090
isWindows,
9191
localIPv6Hosts,

test/common/shared-lib-util.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ function addLibraryPath(env) {
2222
env.LIBPATH =
2323
(env.LIBPATH ? env.LIBPATH + path.delimiter : '') +
2424
kExecPath;
25-
// For Mac OSX.
25+
// For macOS.
2626
env.DYLD_LIBRARY_PATH =
2727
(env.DYLD_LIBRARY_PATH ? env.DYLD_LIBRARY_PATH + path.delimiter : '') +
2828
kExecPath;

test/fixtures/permission/fs-write.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -338,7 +338,7 @@ const relativeProtectedFolder = process.env.RELATIVEBLOCKEDFOLDER;
338338

339339
// fs.lchmod
340340
{
341-
if (common.isOSX) {
341+
if (common.isMacOS) {
342342
fs.lchmod(blockedFile, 0o755, common.expectsError({
343343
code: 'ERR_ACCESS_DENIED',
344344
permission: 'FileSystemWrite',

test/parallel/test-child-process-exec-timeout-expire.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ cp.exec(cmd, {
3838
// At least starting with Darwin Kernel Version 16.4.0, sending a SIGTERM to a
3939
// process that is still starting up kills it with SIGKILL instead of SIGTERM.
4040
// See: https://github.com/libuv/libuv/issues/1226
41-
if (common.isOSX)
41+
if (common.isMacOS)
4242
assert.ok(err.signal === 'SIGTERM' || err.signal === 'SIGKILL');
4343
else
4444
assert.strictEqual(err.signal, sigterm);

test/parallel/test-cluster-bind-privileged-port.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ if (common.isLinux) {
3838
}
3939
}
4040

41-
// Skip on OS X Mojave. https://github.com/nodejs/node/issues/21679
42-
if (common.isOSX)
41+
// Skip on macOS Mojave. https://github.com/nodejs/node/issues/21679
42+
if (common.isMacOS)
4343
common.skip('macOS may allow ordinary processes to use any port');
4444

4545
if (common.isIBMi)

test/parallel/test-cluster-concurrent-disconnect.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ if (cluster.isPrimary) {
2626
// to send messages when the worker is disconnecting.
2727
worker.on('error', (err) => {
2828
assert.strictEqual(err.syscall, 'write');
29-
if (common.isOSX) {
29+
if (common.isMacOS) {
3030
assert(['EPIPE', 'ENOTCONN'].includes(err.code), err);
3131
} else {
3232
assert(['EPIPE', 'ECONNRESET'].includes(err.code), err);

test/parallel/test-cluster-shared-handle-bind-privileged-port.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,8 @@
2222
'use strict';
2323
const common = require('../common');
2424

25-
// Skip on OS X Mojave. https://github.com/nodejs/node/issues/21679
26-
if (common.isOSX)
25+
// Skip on macOS Mojave. https://github.com/nodejs/node/issues/21679
26+
if (common.isMacOS)
2727
common.skip('macOS may allow ordinary processes to use any port');
2828

2929
if (common.isIBMi)

test/parallel/test-fs-lchmod.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ const f = __filename;
99
// This test ensures that input for lchmod is valid, testing for valid
1010
// inputs for path, mode and callback
1111

12-
if (!common.isOSX) {
12+
if (!common.isMacOS) {
1313
common.skip('lchmod is only available on macOS');
1414
}
1515

test/parallel/test-fs-mkdir.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -217,7 +217,7 @@ function nextdir() {
217217

218218
// mkdirpSync dirname loop
219219
// XXX: windows and smartos have issues removing a directory that you're in.
220-
if (common.isMainThread && (common.isLinux || common.isOSX)) {
220+
if (common.isMainThread && (common.isLinux || common.isMacOS)) {
221221
const pathname = tmpdir.resolve(nextdir());
222222
fs.mkdirSync(pathname);
223223
process.chdir(pathname);

test/parallel/test-fs-open-flags.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ assert.throws(
8282
{ code: 'ERR_INVALID_ARG_VALUE', name: 'TypeError' }
8383
);
8484

85-
if (common.isLinux || common.isOSX) {
85+
if (common.isLinux || common.isMacOS) {
8686
const tmpdir = require('../common/tmpdir');
8787
tmpdir.refresh();
8888
const file = tmpdir.resolve('a.js');

test/parallel/test-fs-promises-file-handle-aggregate-errors.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@ async function checkAggregateError(op) {
6565
await checkAggregateError((filePath) => truncate(filePath));
6666
await checkAggregateError((filePath) => readFile(filePath));
6767
await checkAggregateError((filePath) => writeFile(filePath, '123'));
68-
if (common.isOSX) {
68+
if (common.isMacOS) {
6969
await checkAggregateError((filePath) => lchmod(filePath, 0o777));
7070
}
7171
})().then(common.mustCall());

test/parallel/test-fs-promises-file-handle-close-errors.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -60,7 +60,7 @@ async function checkCloseError(op) {
6060
await checkCloseError((filePath) => truncate(filePath));
6161
await checkCloseError((filePath) => readFile(filePath));
6262
await checkCloseError((filePath) => writeFile(filePath, '123'));
63-
if (common.isOSX) {
63+
if (common.isMacOS) {
6464
await checkCloseError((filePath) => lchmod(filePath, 0o777));
6565
}
6666
})().then(common.mustCall());

test/parallel/test-fs-promises-file-handle-op-errors.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ async function checkOperationError(op) {
5454
await checkOperationError((filePath) => truncate(filePath));
5555
await checkOperationError((filePath) => readFile(filePath));
5656
await checkOperationError((filePath) => writeFile(filePath, '123'));
57-
if (common.isOSX) {
57+
if (common.isMacOS) {
5858
await checkOperationError((filePath) => lchmod(filePath, 0o777));
5959
}
6060
})().then(common.mustCall());

test/parallel/test-fs-promises-watch.js

+2-2
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ class WatchTestCase {
2424
const kCases = [
2525
// Watch on a directory should callback with a filename on supported systems
2626
new WatchTestCase(
27-
common.isLinux || common.isOSX || common.isWindows || common.isAIX,
27+
common.isLinux || common.isMacOS || common.isWindows || common.isAIX,
2828
'watch1',
2929
'foo',
3030
'filePath'
3131
),
3232
// Watch on a file should callback with a filename on supported systems
3333
new WatchTestCase(
34-
common.isLinux || common.isOSX || common.isWindows,
34+
common.isLinux || common.isMacOS || common.isWindows,
3535
'watch2',
3636
'bar',
3737
'dirPath'

test/parallel/test-fs-promises.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ async function executeOnHandle(dest, func) {
314314
(await readlink(newLink)).toLowerCase());
315315

316316
const newMode = 0o666;
317-
if (common.isOSX) {
317+
if (common.isMacOS) {
318318
// `lchmod` is only available on macOS.
319319
await lchmod(newLink, newMode);
320320
stats = await lstat(newLink);

test/parallel/test-fs-readdir-buffer.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
const common = require('../common');
33
const fs = require('fs');
44

5-
if (!common.isOSX) {
5+
if (!common.isMacOS) {
66
common.skip('this tests works only on MacOS');
77
}
88

test/parallel/test-fs-watch-enoent.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ tmpdir.refresh();
4646
}
4747

4848
{
49-
if (common.isOSX || common.isWindows) {
49+
if (common.isMacOS || common.isWindows) {
5050
const file = tmpdir.resolve('file-to-watch');
5151
fs.writeFileSync(file, 'test');
5252
const watcher = fs.watch(file, common.mustNotCall());

test/parallel/test-fs-watch-recursive-validate.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ tmpdir.refresh();
2323
(async () => {
2424
// Handle non-boolean values for options.recursive
2525

26-
if (!common.isWindows && !common.isOSX) {
26+
if (!common.isWindows && !common.isMacOS) {
2727
assert.throws(() => {
2828
const testsubdir = fs.mkdtempSync(testDir + path.sep);
2929
fs.watch(testsubdir, { recursive: '1' });

test/parallel/test-fs-watch.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -24,14 +24,14 @@ class WatchTestCase {
2424
const cases = [
2525
// Watch on a file should callback with a filename on supported systems
2626
new WatchTestCase(
27-
common.isLinux || common.isOSX || common.isWindows || common.isAIX,
27+
common.isLinux || common.isMacOS || common.isWindows || common.isAIX,
2828
'watch1',
2929
'foo',
3030
'filePath'
3131
),
3232
// Watch on a directory should callback with a filename on supported systems
3333
new WatchTestCase(
34-
common.isLinux || common.isOSX || common.isWindows,
34+
common.isLinux || common.isMacOS || common.isWindows,
3535
'watch2',
3636
'bar',
3737
'dirPath'
@@ -66,7 +66,7 @@ for (const testCase of cases) {
6666
clearInterval(interval);
6767
interval = null;
6868
}
69-
if (common.isOSX)
69+
if (common.isMacOS)
7070
assert.strictEqual(['rename', 'change'].includes(eventType), true);
7171
else
7272
assert.strictEqual(eventType, 'change');

test/parallel/test-fs-watchfile.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ watcher.on('stop', common.mustCall());
8484

8585
// Watch events should callback with a filename on supported systems.
8686
// Omitting AIX. It works but not reliably.
87-
if (common.isLinux || common.isOSX || common.isWindows) {
87+
if (common.isLinux || common.isMacOS || common.isWindows) {
8888
const dir = tmpdir.resolve('watch');
8989

9090
fs.mkdir(dir, common.mustCall(function(err) {

test/parallel/test-process-getgroups.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ const common = require('../common');
2424

2525
// Check `id -G` and `process.getgroups()` return same groups.
2626

27-
if (common.isOSX)
27+
if (common.isMacOS)
2828
common.skip('Output of `id -G` is unreliable on Darwin.');
2929

3030
const assert = require('assert');

test/parallel/test-stdin-from-file-spawn.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ if (process.platform === 'linux' || process.platform === 'darwin') {
88
} else if (process.platform === 'win32') {
99
defaultShell = 'cmd.exe';
1010
} else {
11-
common.skip('This is test exists only on Linux/Win32/OSX');
11+
common.skip('This is test exists only on Linux/Win32/macOS');
1212
}
1313

1414
const { execSync } = require('child_process');

test/parallel/test-tls-honorcipherorder.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ function test(honorCipherOrder, clientCipher, expectedCipher, defaultCiphers) {
2929

3030
const server = tls.createServer(soptions, mustCall(function(clearTextStream) {
3131
// End socket to send CLOSE_NOTIFY and TCP FIN packet, otherwise
32-
// it may hang for ~30 seconds in FIN_WAIT_1 state (at least on OSX).
32+
// it may hang for ~30 seconds in FIN_WAIT_1 state (at least on macOS).
3333
clearTextStream.end();
3434
}));
3535
server.listen(0, localhost, mustCall(function() {

test/parallel/test-watch-mode-files_watcher.mjs

+1-1
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@ import watcher from 'internal/watch_mode/files_watcher';
1515
if (common.isIBMi)
1616
common.skip('IBMi does not support `fs.watch()`');
1717

18-
const supportsRecursiveWatching = common.isOSX || common.isWindows;
18+
const supportsRecursiveWatching = common.isMacOS || common.isWindows;
1919

2020
const { FilesWatcher } = watcher;
2121
tmpdir.refresh();

test/sequential/test-cluster-send-handle-large-payload.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ if (cluster.isPrimary) {
4343
// Send a second message after a delay on macOS.
4444
//
4545
// Refs: https://github.com/nodejs/node/issues/14747
46-
if (common.isOSX)
46+
if (common.isMacOS)
4747
setTimeout(() => { process.send({ payload }, handle); }, 1000);
4848
else
4949
process.send({ payload }, handle);

0 commit comments

Comments
 (0)