1- // flow-typed signature: 9b9f4128694a7f68659d945b81fb78ff
2- // flow-typed version: 46dfe79a54 /react-test-renderer_v16.x.x/flow_>=v0.47.x
1+ // flow-typed signature: b6bb53397d83d2d821e258cc73818d1b
2+ // flow-typed version: 9c71eca8ef /react-test-renderer_v16.x.x/flow_>=v0.47.x
33
44// Type definitions for react-test-renderer 16.x.x
55// Ported from: https://github.com/DefinitelyTyped/DefinitelyTyped/blob/master/types/react-test-renderer
@@ -9,18 +9,18 @@ type ReactComponentInstance = React$Component<any>;
99type ReactTestRendererJSON = {
1010 type : string ,
1111 props : { [ propName : string ] : any } ,
12- children : null | ReactTestRendererJSON [ ] ,
12+ children : null | ReactTestRendererJSON [ ]
1313} ;
1414
1515type ReactTestRendererTree = ReactTestRendererJSON & {
16- nodeType : ' component' | ' host' ,
16+ nodeType : " component" | " host" ,
1717 instance : ?ReactComponentInstance ,
18- rendered : null | ReactTestRendererTree ,
18+ rendered : null | ReactTestRendererTree
1919} ;
2020
2121type ReactTestInstance = {
2222 instance : ?ReactComponentInstance ,
23- type : string | Function ,
23+ type : string ,
2424 props : { [ propName : string ] : any } ,
2525 parent : null | ReactTestInstance ,
2626 children : Array < ReactTestInstance | string > ,
@@ -40,25 +40,25 @@ type ReactTestInstance = {
4040 findAllByProps (
4141 props : { [ propName : string ] : any } ,
4242 options ? : { deep : boolean }
43- ) : ReactTestInstance [ ] ,
43+ ) : ReactTestInstance [ ]
4444} ;
4545
4646type TestRendererOptions = {
47- createNodeMock ( element : React$Element < any > ) : any ,
48- } ;
49-
50- type Thenable = {
51- then ( resolve : ( ) => mixed , reject ?: ( ) => mixed ) : mixed ,
47+ createNodeMock ( element : React$Element < any > ) : any
5248} ;
5349
54- declare module ' react-test-renderer' {
50+ declare module " react-test-renderer" {
5551 declare export type ReactTestRenderer = {
5652 toJSON ( ) : null | ReactTestRendererJSON ,
5753 toTree ( ) : null | ReactTestRendererTree ,
5854 unmount ( nextElement ?: React$Element < any > ) : void ,
5955 update ( nextElement : React$Element < any > ) : void ,
6056 getInstance ( ) : ?ReactComponentInstance ,
61- root : ReactTestInstance ,
57+ root : ReactTestInstance
58+ } ;
59+
60+ declare type Thenable = {
61+ then ( resolve : ( ) => mixed , reject ?: ( ) => mixed ) : mixed ,
6262 } ;
6363
6464 declare function create (
@@ -69,7 +69,7 @@ declare module 'react-test-renderer' {
6969 declare function act ( callback : ( ) = > void ) : Thenable ;
7070}
7171
72- declare module ' react-test-renderer/shallow' {
72+ declare module " react-test-renderer/shallow" {
7373 declare export default class ShallowRenderer {
7474 static createRenderer ( ) : ShallowRenderer ;
7575 getMountedInstance ( ) : ReactTestInstance ;
0 commit comments