| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
1 parent d3111bf commit f43bfe2
1 file changed
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -104,7 +104,7 @@ more on color support in terminal environments, read the tty | |||
| 104 | 104 | ||
| 105 | 105 | ## Legacy assertion mode | |
| 106 | 106 | ||
| 107 | - Legacy assertion mode uses the `==` operator in: | ||
| 107 | + Legacy assertion mode uses the [`==` operator][] in: | ||
| 108 | 108 | ||
| 109 | 109 | * [`assert.deepEqual()`][] | |
| 110 | 110 | * [`assert.equal()`][] | |
@@ -521,7 +521,7 @@ are also recursively evaluated by the following rules. | |||
| 521 | 521 | ||
| 522 | 522 | ### Comparison details | |
| 523 | 523 | ||
| 524 | - * Primitive values are compared with the `==` operator, | ||
| 524 | + * Primitive values are compared with the [`==` operator][], | ||
| 525 | 525 | with the exception of `NaN`. It is treated as being identical in case | |
| 526 | 526 | both sides are `NaN`. | |
| 527 | 527 | * [Type tags][Object.prototype.toString()] of objects should be the same. | |
@@ -539,7 +539,7 @@ are also recursively evaluated by the following rules. | |||
| 539 | 539 | * [`WeakMap`][] and [`WeakSet`][] comparison does not rely on their values. | |
| 540 | 540 | ||
| 541 | 541 | The following example does not throw an [`AssertionError`][] because the | |
| 542 | - primitives are compared using the `==` operator. | ||
| 542 | + primitives are compared using the [`==` operator][]. | ||
| 543 | 543 | ||
| 544 | 544 | ```mjs | |
| 545 | 545 | import assert from 'assert'; | |
@@ -1156,7 +1156,7 @@ An alias of [`assert.strictEqual()`][]. | |||
| 1156 | 1156 | > Stability: 3 - Legacy: Use [`assert.strictEqual()`][] instead. | |
| 1157 | 1157 | ||
| 1158 | 1158 | Tests shallow, coercive equality between the `actual` and `expected` parameters | |
| 1159 | - using the `==` operator. `NaN` is specially handled | ||
| 1159 | + using the [`==` operator][]. `NaN` is specially handled | ||
| 1160 | 1160 | and treated as being identical if both sides are `NaN`. | |
| 1161 | 1161 | ||
| 1162 | 1162 | ```mjs | |
@@ -1674,9 +1674,8 @@ An alias of [`assert.notStrictEqual()`][]. | |||
| 1674 | 1674 | ||
| 1675 | 1675 | > Stability: 3 - Legacy: Use [`assert.notStrictEqual()`][] instead. | |
| 1676 | 1676 | ||
| 1677 | - Tests shallow, coercive inequality with the | ||
| 1678 | - `!=` operator. `NaN` is specially handled and treated as being identical if | ||
| 1679 | - sides are `NaN`. | ||
| 1677 | + Tests shallow, coercive inequality with the [`!=` operator][]. `NaN` is | ||
| 1678 | + specially handled and treated as being identical if both sides are `NaN`. | ||
| 1680 | 1679 | ||
| 1681 | 1680 | ```mjs | |
| 1682 | 1681 | import assert from 'assert'; | |
@@ -2439,6 +2438,8 @@ argument. | |||
| 2439 | 2438 | [Object.prototype.toString()]: https://tc39.github.io/ecma262/#sec-object.prototype.tostring | |
| 2440 | 2439 | [SameValue Comparison]: https://tc39.github.io/ecma262/#sec-samevalue | |
| 2441 | 2440 | [Strict Equality Comparison]: https://tc39.github.io/ecma262/#sec-strict-equality-comparison | |
| 2441 | + [`!=` operator]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Inequality | ||
| 2442 | + [`==` operator]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Operators/Equality | ||
| 2442 | 2443 | [`AssertionError`]: #class-assertassertionerror | |
| 2443 | 2444 | [`CallTracker`]: #class-assertcalltracker | |
| 2444 | 2445 | [`Class`]: https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Classes | |
| Back | FazBrowse Home | New Git URL |
0 commit comments