Skip to content

Commit 9c9138f

Browse files
dmabupttargos
authored andcommitted
test: skip the unsupported test cases for IBM i
This is a following PR of #30714. PR-URL: #30819 Reviewed-By: Anna Henningsen <[email protected]> Reviewed-By: James M Snell <[email protected]> Reviewed-By: Ruben Bridgewater <[email protected]>
1 parent 2aab93e commit 9c9138f

29 files changed

+108
-21
lines changed

test/async-hooks/test-fseventwrap.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,9 @@ const fs = require('fs');
1010
if (!common.isMainThread)
1111
common.skip('Worker bootstrapping works differently -> different async IDs');
1212

13+
if (common.isIBMi)
14+
common.skip('IBMi does not suppport fs.watch()');
15+
1316
const hooks = initHooks();
1417

1518
hooks.enable();

test/parallel/parallel.status

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,3 +43,12 @@ test-async-hooks-http-parser-destroy: PASS,FLAKY
4343
[$system==freebsd]
4444

4545
[$system==aix]
46+
47+
[$system==ibmi]
48+
# https://github.com/nodejs/node/pull/30819
49+
test-child-process-fork-net-server: SKIP
50+
test-cli-node-options: SKIP
51+
test-cluster-shared-leak: SKIP
52+
test-http-writable-true-after-close: SKIP
53+
test-http2-connect-method: SKIP
54+
test-net-error-twice: SKIP

test/parallel/test-c-ares.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,8 @@ dns.lookup('::1', common.mustCall((error, result, addressType) => {
8585
// Windows doesn't usually have an entry for localhost 127.0.0.1 in
8686
// C:\Windows\System32\drivers\etc\hosts
8787
// so we disable this test on Windows.
88-
if (!common.isWindows) {
88+
// IBMi reports `ENOTFOUND` when get hostname by address 127.0.0.1
89+
if (!common.isWindows && !common.isIBMi) {
8990
dns.reverse('127.0.0.1', common.mustCall(function(error, domains) {
9091
assert.ifError(error);
9192
assert.ok(Array.isArray(domains));

test/parallel/test-child-process-spawnsync-validation-errors.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,8 @@ const common = require('../common');
33
const assert = require('assert');
44
const spawnSync = require('child_process').spawnSync;
55
const signals = require('os').constants.signals;
6-
const rootUser = common.isWindows ? false : process.getuid() === 0;
6+
const rootUser = common.isWindows ? false :
7+
common.isIBMi ? true : process.getuid() === 0;
78

89
const invalidArgTypeError = common.expectsError(
910
{ code: 'ERR_INVALID_ARG_TYPE', type: TypeError },

test/parallel/test-child-process-uid-gid.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,9 @@ const assert = require('assert');
44
const spawn = require('child_process').spawn;
55
const expectedError = common.isWindows ? /\bENOTSUP\b/ : /\bEPERM\b/;
66

7+
if (common.isIBMi)
8+
common.skip('IBMi has a different behavior');
9+
710
if (common.isWindows || process.getuid() !== 0) {
811
assert.throws(() => {
912
spawn('echo', ['fhqwhgads'], { uid: 0 });

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ const common = require('../common');
2626
if (common.isOSX)
2727
common.skip('macOS may allow ordinary processes to use any port');
2828

29+
if (common.isIBMi)
30+
common.skip('IBMi may allow ordinary processes to use any port');
31+
2932
if (common.isWindows)
3033
common.skip('not reliable on Windows');
3134

test/parallel/test-fs-access.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ const common = require('../common');
88
if (!common.isWindows && process.getuid() === 0)
99
common.skip('as this test should not be run as `root`');
1010

11+
if (common.isIBMi)
12+
common.skip('IBMi has a different access permission mechanism');
13+
1114
const assert = require('assert');
1215
const fs = require('fs');
1316
const path = require('path');

test/parallel/test-fs-copyfile-respect-permissions.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ const common = require('../common');
88
if (!common.isWindows && process.getuid() === 0)
99
common.skip('as this test should not be run as `root`');
1010

11+
if (common.isIBMi)
12+
common.skip('IBMi has a different access permission mechanism');
13+
1114
const tmpdir = require('../common/tmpdir');
1215
tmpdir.refresh();
1316

test/parallel/test-fs-options-immutable.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,7 @@ if (common.canCreateSymLink()) {
4646
fs.appendFile(fileName, 'ABCD', options, common.mustCall(errHandler));
4747
}
4848

49-
{
49+
if (!common.isIBMi) { // IBMi does not suppport fs.watch()
5050
const watch = fs.watch(__filename, options, common.mustNotCall());
5151
watch.close();
5252
}

test/parallel/test-fs-utimes.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -144,8 +144,9 @@ function runTests(iter) {
144144
const path = `${tmpdir.path}/test-utimes-precision`;
145145
fs.writeFileSync(path, '');
146146

147-
// Test Y2K38 for all platforms [except 'arm', 'OpenBSD' and 'SunOS']
148-
if (!process.arch.includes('arm') && !common.isOpenBSD && !common.isSunOS) {
147+
// Test Y2K38 for all platforms [except 'arm', 'OpenBSD', 'SunOS' and 'IBMi']
148+
if (!process.arch.includes('arm') &&
149+
!common.isOpenBSD && !common.isSunOS && !common.isIBMi) {
149150
const Y2K38_mtime = 2 ** 31;
150151
fs.utimesSync(path, Y2K38_mtime, Y2K38_mtime);
151152
const Y2K38_stats = fs.statSync(path);

0 commit comments

Comments
 (0)