DefinitelyTyped/types/jest-json-schema/index.d.ts
Matt Scheurich 7823adabc9 Updated types for jest-json-schema@2.1 (#38465)
* updated jest-json-schema types with latest version of Ajv and support for extendAjv in matchersWithOptions

* updated jest-json-schema version in header

* removed patch version from header
2019-09-25 16:31:18 -07:00

22 lines
731 B
TypeScript

// Type definitions for jest-json-schema 2.1
// Project: https://github.com/americanexpress/jest-json-schema#readme
// Definitions by: Igor Korolev <https://github.com/deadNightTiger>
// Matt Scheurich <https://github.com/lvl99>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 3.0
/// <reference types="jest" />
import * as ajv from 'ajv';
declare global {
namespace jest {
interface Matchers<R> {
toBeValidSchema(): R;
toMatchSchema(schema: object): R;
}
}
}
export const matchers: jest.ExpectExtendMap;
export function matchersWithOptions(options: ajv.Options, extendAjv?: (ajv: ajv.Ajv) => void): jest.ExpectExtendMap;