node:assert

Node's assertion module, with one difference in AssertionError.operator.

node:assert and node:assert/strict match Node; import them with import assert from "node:assert".

Differences from Node

  • AssertionError.operator holds the method name (strictEqual), not a symbol (===).