MCPcopy
hub / github.com/faker-js/faker / MethodTester

Interface MethodTester

test/support/seeded-runs.ts:381–403  ·  view source on GitHub ↗

* Simple interface for a test generator for a given method.

Source from the content-addressed store, hash-verified

379 * Simple interface for a test generator for a given method.
380 */
381interface MethodTester<TMethod extends Callable> {
382 /**
383 * Generates a test for the method.
384 *
385 * @param name The name of the test case.
386 * @param args The arguments to use in the test.
387 */
388 it(name: string, ...args: Parameters<TMethod>): this;
389
390 /**
391 * Generates a repeated test for the method.
392 * The seed is not reset between repetitions.
393 *
394 * @param name The name of the test case.
395 * @param repetitions The number of repetitions to run.
396 * @param args The arguments to use in the test.
397 */
398 itRepeated(
399 name: string,
400 repetitions: number,
401 ...args: Parameters<TMethod>
402 ): this;
403}

Callers 10

system.spec.tsFile · 0.65
location.spec.tsFile · 0.65
commerce.spec.tsFile · 0.65
lorem.spec.tsFile · 0.65
person.spec.tsFile · 0.65
image.spec.tsFile · 0.65
food.spec.tsFile · 0.65
git.spec.tsFile · 0.65
datatype.spec.tsFile · 0.65
string.spec.tsFile · 0.65

Implementers 1

TestGeneratortest/support/seeded-runs.ts

Calls

no outgoing calls

Tested by

no test coverage detected