assertNotStrictEquals
import { assertNotStrictEquals } from "jsr:@ende/assert";function
function assertNotStrictEquals<T>(actual: T, expected: T, msg?: string): voidMake an assertion that actual and expected are not strictly equal, using
Object.is for equality comparison. If the values are strictly
equal then throw.
actual: TThe actual value to compare.
expected: TThe expected value to compare.
msg?: stringThe optional message to display if the assertion fails.
Example: Usage
import { assertNotStrictEquals } from "@ende/assert";
assertNotStrictEquals(1, 1); // Throws
assertNotStrictEquals(1, 2); // Doesn't throw
assertNotStrictEquals(0, 0); // Throws
assertNotStrictEquals(0, -0); // Doesn't throw