rc-js-util
Version:
A collection of TS and C++ utilities to help writing performant and correct applications, achieved through strict typing and (removable) invariant checking.
17 lines (15 loc) • 447 B
text/typescript
import { _Debug } from "./_debug.js";
describe("=> _Debug.error", () =>
{
describe("=> compilation checks", () =>
{
it("| has the right ergonomics", () =>
{
_BUILD.DEBUG && _Debug.assert(Math.random() > -1, "this is always true");
});
});
it("| throws an error with the expected message", () =>
{
expect(() => _Debug.error("test message")).toThrowError("test message");
});
});