std/testing/mock.ts

Deno standard library
Go to Latest
function returnsArgs
import { returnsArgs } from "https://deno.land/std@0.146.0/testing/mock.ts?s=returnsArgs";

Creates a function that returns its arguments or a subset of them. If end is specified, it will return arguments up to but not including the end.

Type Parameters

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

Parameters

optional
start
[src]
optional
end: number
[src]

Returns

(this: Self, ...args: Args) => Args[src]