Skip to content

Commit

Permalink
test: use assert.strictEqual instead of assert.equal
Browse files Browse the repository at this point in the history
PR-URL: #23673
Reviewed-By: Ruben Bridgewater <ruben@bridgewater.de>
Reviewed-By: Refael Ackermann <refack@gmail.com>
  • Loading branch information
prog1dev authored and BridgeAR committed Nov 13, 2018
1 parent 6f80a45 commit 2b0410a
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions test/pseudo-tty/test-tty-get-color-depth.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const writeStream = new WriteStream(fd);

{
const depth = writeStream.getColorDepth();
assert.equal(typeof depth, 'number');
assert.strictEqual(typeof depth, 'number');
assert(depth >= 1 && depth <= 24);
}

Expand Down Expand Up @@ -44,7 +44,7 @@ const writeStream = new WriteStream(fd);
[{ TERM: 'dumb', COLORTERM: '1' }, 4],
].forEach(([env, depth], i) => {
const actual = writeStream.getColorDepth(env);
assert.equal(
assert.strictEqual(
actual,
depth,
`i: ${i}, expected: ${depth}, actual: ${actual}, env: ${env}`
Expand All @@ -57,8 +57,8 @@ const writeStream = new WriteStream(fd);
const [ value, depth1, depth2 ] = process.platform !== 'win32' ?
['win32', 1, 4] : ['linux', 4, 1];

assert.equal(writeStream.getColorDepth({}), depth1);
assert.strictEqual(writeStream.getColorDepth({}), depth1);
Object.defineProperty(process, 'platform', { value });
assert.equal(writeStream.getColorDepth({}), depth2);
assert.strictEqual(writeStream.getColorDepth({}), depth2);
Object.defineProperty(process, 'platform', platform);
}

0 comments on commit 2b0410a

Please sign in to comment.