Skip to main content
Module

std/_util/asserts.ts

Deno standard library
Go to Latest
import * as mod from "https://deno.land/std@0.166.0/_util/asserts.ts";

Classes

All internal non-test code, that is files that do not have test or bench in the name, must use the assertion functions within _utils/asserts.ts and not testing/asserts.ts. This is to create a separation of concerns between internal and testing assertions.

Functions

Make an assertion, if not true, then throw.

Use this to assert unreachable code.