// flow-typed signature: 055d97c4302b7989c7221251421dca7c // flow-typed version: 673c7738c2/chai_v4.x.x/flow_>=v0.104.x declare module "chai" { declare type ExpectChain = { and: ExpectChain, at: ExpectChain, be: ExpectChain, been: ExpectChain, have: ExpectChain, has: ExpectChain, is: ExpectChain, of: ExpectChain, same: ExpectChain, that: ExpectChain, to: ExpectChain, which: ExpectChain, with: ExpectChain, not: ExpectChain, deep: ExpectChain, any: ExpectChain, all: ExpectChain, own: ExpectChain, a: ExpectChain & ((type: string, message?: string) => ExpectChain), an: ExpectChain & ((type: string, message?: string) => ExpectChain), include: ExpectChain & ((value: mixed, message?: string) => ExpectChain), includes: ExpectChain & ((value: mixed, message?: string) => ExpectChain), contain: ExpectChain & ((value: mixed, message?: string) => ExpectChain), contains: ExpectChain & ((value: mixed, message?: string) => ExpectChain), eq: (value: T, message?: string) => ExpectChain, eql: (value: T, message?: string) => ExpectChain, equal: (value: T, message?: string) => ExpectChain, equals: (value: T, message?: string) => ExpectChain, above: (value: T & number, message?: string) => ExpectChain, gt: (value: T & number, message?: string) => ExpectChain, greaterThan: (value: T & number, message?: string) => ExpectChain, least: (value: T & number, message?: string) => ExpectChain, below: (value: T & number, message?: string) => ExpectChain, lessThan: (value: T & number, message?: string) => ExpectChain, lt: (value: T & number, message?: string) => ExpectChain, most: (value: T & number, message?: string) => ExpectChain, within: (start: T & number, finish: T & number, message?: string) => ExpectChain, instanceof: (constructor: mixed, message?: string) => ExpectChain, instanceOf: (constructor: mixed, message?: string) => ExpectChain, nested: ExpectChain, property:

( name: string, value?: P, message?: string ) => ExpectChain

& ((name: string) => ExpectChain), length: ExpectChain & ((value: number, message?: string) => ExpectChain), lengthOf: (value: number, message?: string) => ExpectChain, match: (regex: RegExp, message?: string) => ExpectChain, matches: (regex: RegExp, message?: string) => ExpectChain, string: (string: string, message?: string) => ExpectChain, key: (key: string) => ExpectChain, keys: ( key: string | Array, ...keys: Array ) => ExpectChain, throw: ( err?: Class | Error | RegExp | string, errMsgMatcher?: RegExp | string, msg?: string ) => ExpectChain, respondTo: (method: string, message?: string) => ExpectChain, itself: ExpectChain, satisfy: (method: (value: T) => boolean, message?: string) => ExpectChain, closeTo: (expected: T & number, delta: number, message?: string) => ExpectChain, members: (set: mixed, message?: string) => ExpectChain, oneOf: (list: Array, message?: string) => ExpectChain, change: (obj: mixed, key: string, message?: string) => ExpectChain, increase: (obj: mixed, key: string, message?: string) => ExpectChain, decrease: (obj: mixed, key: string, message?: string) => ExpectChain, by: (delta: number, message?: string) => ExpectChain, ordered: ExpectChain, // dirty-chai ok: () => ExpectChain, true: () => ExpectChain, false: () => ExpectChain, null: () => ExpectChain, undefined: () => ExpectChain, exist: () => ExpectChain, empty: () => ExpectChain, extensible: () => ExpectChain, sealed: () => ExpectChain, frozen: () => ExpectChain, NaN: () => ExpectChain, // chai-immutable size: (n: number) => ExpectChain, // sinon-chai called: () => ExpectChain, callCount: (n: number) => ExpectChain, calledOnce: () => ExpectChain, calledTwice: () => ExpectChain, calledThrice: () => ExpectChain, calledBefore: (spy: mixed) => ExpectChain, calledAfter: (spy: mixed) => ExpectChain, calledImmediatelyBefore: (spy: mixed) => ExpectChain, calledImmediatelyAfter: (spy: mixed) => ExpectChain, calledWith: (...args: Array) => ExpectChain, calledOnceWith: (...args: Array) => ExpectChain, calledWithMatch: (...args: Array) => ExpectChain, calledWithExactly: (...args: Array) => ExpectChain, calledOnceWithExactly: (...args: Array) => ExpectChain, returned: (returnVal: mixed) => ExpectChain, alwaysReturned: (returnVal: mixed) => ExpectChain, // chai-as-promised eventually: ExpectChain, resolvedWith: (value: mixed) => Promise & ExpectChain, resolved: () => Promise & ExpectChain, rejectedWith: ( value: mixed, errMsgMatcher?: RegExp | string, msg?: string ) => Promise & ExpectChain, rejected: () => Promise & ExpectChain, notify: (callback: () => mixed) => ExpectChain, fulfilled: () => Promise & ExpectChain, // chai-subset containSubset: (obj: {...} | Array< {...} >) => ExpectChain, // chai-redux-mock-store dispatchedActions: ( actions: Array<{...} | ((action: {...}) => any)> ) => ExpectChain, dispatchedTypes: (actions: Array) => ExpectChain, // chai-enzyme attr: (key: string, val?: any) => ExpectChain, data: (key: string, val?: any) => ExpectChain, prop: (key: string, val?: any) => ExpectChain, state: (key: string, val?: any) => ExpectChain, value: (val: string) => ExpectChain, className: (val: string) => ExpectChain, text: (val: string) => ExpectChain, // chai-karma-snapshot matchSnapshot: (lang?: any, update?: boolean, msg?: any) => ExpectChain, ... }; declare var expect: { (actual: T, message?: string): ExpectChain, fail: ((message?: string) => void) & ((actual: any, expected: any, message?: string, operator?: string) => void), ... }; declare function use(plugin: (chai: Object, utils: Object) => void): void; declare class assert { static (expression: mixed, message?: string): void; static fail( actual: mixed, expected: mixed, message?: string, operator?: string ): void; static isOk(object: mixed, message?: string): void; static isNotOk(object: mixed, message?: string): void; static empty(object: mixed, message?: string): void; static isEmpty(object: mixed, message?: string): void; static notEmpty(object: mixed, message?: string): void; static isNotEmpty(object: mixed, message?: string): void; static equal(actual: mixed, expected: mixed, message?: string): void; static notEqual(actual: mixed, expected: mixed, message?: string): void; static strictEqual(act: mixed, exp: mixed, msg?: string): void; static notStrictEqual(act: mixed, exp: mixed, msg?: string): void; static deepEqual(act: mixed, exp: mixed, msg?: string): void; static notDeepEqual(act: mixed, exp: mixed, msg?: string): void; static ok(val: mixed, msg?: string): void; static isTrue(val: mixed, msg?: string): void; static isNotTrue(val: mixed, msg?: string): void; static isFalse(val: mixed, msg?: string): void; static isNotFalse(val: mixed, msg?: string): void; static isNull(val: mixed, msg?: string): void; static isNotNull(val: mixed, msg?: string): void; static isUndefined(val: mixed, msg?: string): void; static isDefined(val: mixed, msg?: string): void; static isNaN(val: mixed, msg?: string): void; static isNotNaN(val: mixed, msg?: string): void; static isAbove(val: number, abv: number, msg?: string): void; static isBelow(val: number, blw: number, msg?: string): void; static exists(val : mixed, msg? : string) : void; static notExists(val : mixed, msg? : string) : void; static isAtMost(val: number, atmst: number, msg?: string): void; static isAtLeast(val: number, atlst: number, msg?: string): void; static isFunction(val: mixed, msg?: string): void; static isNotFunction(val: mixed, msg?: string): void; static isObject(val: mixed, msg?: string): void; static isNotObject(val: mixed, msg?: string): void; static isArray(val: mixed, msg?: string): void; static isNotArray(val: mixed, msg?: string): void; static isString(val: mixed, msg?: string): void; static isNotString(val: mixed, msg?: string): void; static isNumber(val: mixed, msg?: string): void; static isNotNumber(val: mixed, msg?: string): void; static isBoolean(val: mixed, msg?: string): void; static isNotBoolean(val: mixed, msg?: string): void; static typeOf(val: mixed, type: string, msg?: string): void; static notTypeOf(val: mixed, type: string, msg?: string): void; static instanceOf(val: mixed, constructor: Class< * >, msg?: string): void; static notInstanceOf(val: mixed, constructor: Class< * >, msg?: string): void; static include(exp: string, inc: mixed, msg?: string): void; static include(exp: Array, inc: T, msg?: string): void; static notInclude(exp: string, inc: mixed, msg?: string): void; static notInclude(exp: Array, inc: T, msg?: string): void; static deepInclude(haystack : T[] | string, needle : $Shape, msg?: string) : void; static notDeepInclude(haystack : T[] | string, needle : $Shape, msg?: string) : void; static match(exp: mixed, re: RegExp, msg?: string): void; static notMatch(exp: mixed, re: RegExp, msg?: string): void; static property(obj: Object, prop: string, msg?: string): void; static notProperty(obj: Object, prop: string, msg?: string): void; static deepProperty(obj: Object, prop: string, msg?: string): void; static notDeepProperty(obj: Object, prop: string, msg?: string): void; static propertyVal( obj: Object, prop: string, val: mixed, msg?: string ): void; static propertyNotVal( obj: Object, prop: string, val: mixed, msg?: string ): void; static deepPropertyVal( obj: Object, prop: string, val: mixed, msg?: string ): void; static deepPropertyNotVal( obj: Object, prop: string, val: mixed, msg?: string ): void; static lengthOf(exp: mixed, len: number, msg?: string): void; static throws( func: () => any, err?: Class | Error | RegExp | string, errorMsgMatcher?: string | RegExp, msg?: string ): void; static doesNotThrow( func: () => any, err?: Class | Error | RegExp | string, errorMsgMatcher?: string | RegExp, msg?: string ): void; static closeTo( actual: number, expected: number, delta: number, msg?: string ): void; static approximately( actual: number, expected: number, delta: number, msg?: string ): void; // chai-immutable static sizeOf(val: mixed, length: number): void; } declare var config: { includeStack: boolean, showDiff: boolean, truncateThreshold: number, ... }; }