UNPKG

jest-date

Version:

Custom jest matchers to test dates

18 lines (17 loc) 449 B
/// <reference types="jest" /> declare global { namespace jest { interface Matchers<R, T> { /** * Assert whether a date is wednesday or not. * @example * expect(new Date()).toBeWednesday() */ toBeWednesday(): R; } } } export declare function toBeWednesday(this: jest.MatcherUtils, received: Date): { pass: boolean; message: () => string; };