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

x/hex/src/lib/stdx/testing.ts>mock.Stub

An ecosystem delivering practices, philosophy and portability. Powered By Deno and JavaScript.
Latest
interface mock.Stub
implements Spy<Self, Args, Return>
import { type mock } from "https://deno.land/x/hex@0.6.5/src/lib/stdx/testing.ts";
const { Stub } = mock;

An instance method replacement that records all calls made to it.

Type Parameters

optional
Self = any
optional
Args extends unknown[] = any[]
optional
Return = any

Properties

fake: (this: Self, ...args: Args) => Return

The function that is used instead of the original.