Skip to content

Commit c66f71d

Browse files
committed
os: add test for signals constant immutability
1 parent f304f91 commit c66f71d

File tree

1 file changed

+12
-0
lines changed

1 file changed

+12
-0
lines changed
Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
'use strict';
2+
3+
const common = require('../common');
4+
const { test } = require('node:test');
5+
const assert = require('node:assert');
6+
const { constants } = require('node:os');
7+
8+
const { internalBinding } = require('internal/test/binding');
9+
10+
test('Verify that signals constant is immutable', () => {
11+
assert.throws(() => constants.signals.FOOBAR = 1337, TypeError);
12+
})

0 commit comments

Comments
 (0)