Skip to main content
Using Deno in production at your company? Earn free Deno merch.
Give us feedback


Deno standard library
Go to Latest
interface Expected
import { type Expected } from "";


lastCalledWith(...expected: unknown[]): void
lastReturnedWith(expected: unknown): void
nthCalledWith(nth: number, ...expected: unknown[]): void
nthReturnedWith(nth: number, expected: unknown): void
toBeCalled(): void
toBeCalledTimes(expected: number): void
toBeCalledWith(...expected: unknown[]): void
toBeCloseTo(candidate: number, tolerance?: number): void
toBeDefined(): void
toBeFalsy(): void
toBeGreaterThan(expected: number): void
toBeGreaterThanOrEqual(expected: number): void
toBeInstanceOf<T extends AnyConstructor>(expected: T): void
toBeLessThan(expected: number): void
toBeLessThanOrEqual(expected: number): void
toBeNaN(): void
toBeNull(): void
toBeTruthy(): void
toBeUndefined(): void
toBe(expected: unknown): void
toContainEqual(expected: unknown): void
toContain(expected: unknown): void
toEqual(expected: unknown): void
toHaveBeenCalledTimes(expected: number): void
toHaveBeenCalledWith(...expected: unknown[]): void
toHaveBeenCalled(): void
toHaveBeenLastCalledWith(...expected: unknown[]): void
toHaveBeenNthCalledWith(nth: number, ...expected: unknown[]): void
toHaveLength(expected: number): void
toHaveLastReturnedWith(expected: unknown): void
toHaveNthReturnedWith(nth: number, expected: unknown): void
toHaveProperty(propName: string | string[], value?: unknown): void
toHaveReturnedTimes(expected: number): void
toHaveReturnedWith(expected: unknown): void
toHaveReturned(): void
toMatch(expected: RegExp): void
toMatchObject(expected: Record<PropertyKey, unknown>): void
toReturn(): void
toReturnTimes(expected: number): void
toReturnWith(expected: unknown): void
toStrictEqual(candidate: unknown): void
toThrow<E extends Error = Error>(expected?: new (...args: any[]) => E): void