diff --git a/flow/jest.js b/flow/jest.js index d26ab844e..799978ca4 100644 --- a/flow/jest.js +++ b/flow/jest.js @@ -1143,6 +1143,17 @@ declare function spyOn(value: mixed, method: string): Object; /** Holds all functions related to manipulating test runner */ declare var jest: JestObjectType; +/** + * https://jasmine.github.io/2.4/custom_reporter.html + */ +type JasmineReporter = { + jasmineStarted?: (suiteInfo: mixed) => void, + suiteStarted?: (result: mixed) => void, + specStarted?: (result: mixed) => void, + specDone?: (result: mixed) => void, + suiteDone?: (result: mixed) => void, +}; + /** * The global Jasmine object, this is generally not exposed as the public API, * using features inside here could break in later versions of Jest. @@ -1158,6 +1169,7 @@ declare var jasmine: { baseName: string, methodNames: Array, ): {[methodName: string]: JestSpyType}, + getEnv(): {addReporter: (jasmineReporter: JasmineReporter) => void}, objectContaining(value: Object): Object, stringMatching(value: string): string, };