8000
We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
There was an error while loading. Please 8000 reload this page.
1 parent 9862912 commit e1f54e2Copy full SHA for e1f54e2
test/parallel/test-os.js
@@ -83,11 +83,12 @@ assert.ok(hostname.length > 0);
83
84
// IBMi process priority is different.
85
if (!common.isIBMi) {
86
- const DUMMY_PRIORITY = 10;
87
- os.setPriority(DUMMY_PRIORITY);
+ const { PRIORITY_BELOW_NORMAL, PRIORITY_LOW } = os.constants.priority;
+ const LOWER_PRIORITY = os.getPriority() > PRIORITY_BELOW_NORMAL ? PRIORITY_BELOW_NORMAL : PRIORITY_LOW;
88
+ os.setPriority(LOWER_PRIORITY);
89
const priority = os.getPriority();
90
is.number(priority);
- assert.strictEqual(priority, DUMMY_PRIORITY);
91
+ assert.strictEqual(priority, LOWER_PRIORITY);
92
}
93
94
// On IBMi, os.uptime() returns 'undefined'
0 commit comments