UNPKG

@thisisagile/easy-test

Version:

Straightforward library for testing microservices built with @thisisagile/easy

32 lines (31 loc) 1.56 kB
import { Response } from '../utils/Response'; export declare const toHaveStatus: (res: Response, code: number) => jest.CustomMatcherResult; export declare const toBeOk: (res: Response) => jest.CustomMatcherResult; export declare const toBeCreated: (res: Response) => jest.CustomMatcherResult; export declare const toHaveNoContent: (res: Response) => jest.CustomMatcherResult; export declare const toBeBadRequest: (res: Response) => jest.CustomMatcherResult; export declare const toBeUnauthorized: (res: Response) => jest.CustomMatcherResult; export declare const toBeForbidden: (res: Response) => jest.CustomMatcherResult; export declare const toBeNotFound: (res: Response) => jest.CustomMatcherResult; export declare const toBeConflict: (res: Response) => jest.CustomMatcherResult; export declare const toBeInternalServerError: (res: Response) => jest.CustomMatcherResult; export declare const toBeBadGateway: (res: Response) => jest.CustomMatcherResult; export declare const toBeOkWithItems: (res: Response, length: number) => jest.CustomMatcherResult; declare global { namespace jest { interface Matchers<R, T> { toBeOk(): R; toBeOkWithItems(length: number): R; toBeCreated(): R; toHaveNoContent(): R; toBeNotFound(): R; toBeUnauthorized(): R; toBeForbidden(): R; toBeBadRequest(): R; toBeConflict(): R; toBeInternalServerError(): R; toBeBadGateway(): R; toHaveStatus(code: number): R; } } }