@case-contract-testing/case
Version:
Next-generation contract testing suite
37 lines (36 loc) • 1.1 kB
TypeScript
import { type CoreAndCombinationMatcher } from '../../../entities/types';
import type { BooleanMatcher, NullMatcher, NumberMatcher, StringMatcher } from './types';
/**
* Matches any number.
*
* When in a JSON match context, this will be following [RFC 8259 JSON](https://www.rfc-editor.org/rfc/rfc8259) - ie, not NaN or Infinity
*
* @param example - An example number
*/
export declare const anyNumber: (example?: number) => NumberMatcher;
/**
* Matches any integer.
*
* @param example - An example integer
*/
export declare const anyInteger: (example?: number) => CoreAndCombinationMatcher;
/**
* Matches any string.
*
* @param example - An example string
*/
export declare const anyString: (example?: string) => StringMatcher;
/**
* Matches any Boolean.
*
* @param example - An example boolean
*/
export declare const anyBoolean: (example?: boolean) => BooleanMatcher;
/**
* Matches any null.
*
* You don't actually need this matcher, you can just use the literal `null`
*
* @param example - An example null
*/
export declare const anyNull: (example?: null) => NullMatcher;