Skip to content

Commit

Permalink
deploy 120 to xplat
Browse files Browse the repository at this point in the history
Summary:
Changelog: [Internal]

bypass-lint
allow-large-files

Reviewed By: mroch

Differential Revision: D20290164

fbshipit-source-id: 6f8633b1a8685b0551757fc4841b82eab77525c5
  • Loading branch information
Daniel Sainati authored and facebook-github-bot committed Mar 6, 2020
1 parent 78de086 commit 1beef1e
Show file tree
Hide file tree
Showing 10 changed files with 26 additions and 24 deletions.
2 changes: 1 addition & 1 deletion .flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -85,4 +85,4 @@ untyped-import
untyped-type-import

[version]
^0.119.0
^0.120.0
2 changes: 1 addition & 1 deletion .flowconfig.android
Original file line number Diff line number Diff line change
Expand Up @@ -85,4 +85,4 @@ untyped-import
untyped-type-import

[version]
^0.119.0
^0.120.0
3 changes: 3 additions & 0 deletions Libraries/Animated/src/AnimatedEvent.js
Original file line number Diff line number Diff line change
Expand Up @@ -210,6 +210,9 @@ class AnimatedEvent {
}
} else if (typeof recMapping === 'object') {
for (const mappingKey in recMapping) {
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found
* when Flow v0.120 was deployed. To see the error, delete this
* comment and run Flow. */
traverse(recMapping[mappingKey], recEvt[mappingKey], mappingKey);
}
}
Expand Down
9 changes: 0 additions & 9 deletions Libraries/Animated/src/AnimatedImplementation.js
Original file line number Diff line number Diff line change
Expand Up @@ -170,9 +170,6 @@ const spring = function(

_startNativeLoop: function(iterations?: number): void {
const singleConfig = {...config, iterations};
/* $FlowFixMe(>=0.111.0 site=react_native_fb) This comment suppresses
* an error found when Flow v0.111 was deployed. To see the error,
* delete this comment and run Flow. */
start(value, singleConfig);
},

Expand Down Expand Up @@ -227,9 +224,6 @@ const timing = function(

_startNativeLoop: function(iterations?: number): void {
const singleConfig = {...config, iterations};
/* $FlowFixMe(>=0.111.0 site=react_native_fb) This comment suppresses
* an error found when Flow v0.111 was deployed. To see the error,
* delete this comment and run Flow. */
start(value, singleConfig);
},

Expand Down Expand Up @@ -272,9 +266,6 @@ const decay = function(

_startNativeLoop: function(iterations?: number): void {
const singleConfig = {...config, iterations};
/* $FlowFixMe(>=0.111.0 site=react_native_fb) This comment suppresses
* an error found when Flow v0.111 was deployed. To see the error,
* delete this comment and run Flow. */
start(value, singleConfig);
},

Expand Down
17 changes: 13 additions & 4 deletions Libraries/Utilities/ReactNativeTestTools.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,18 +16,19 @@ const React = require('react');

const ReactTestRenderer = require('react-test-renderer');
const ShallowRenderer = require('react-test-renderer/shallow');
// $FlowFixMe - error revealed when flow-typing ReactTestRenderer
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when Flow
* v0.120 was deployed. To see the error, delete this comment and run Flow. */
const shallowRenderer = new ShallowRenderer();

import type {ReactTestRenderer as ReactTestRendererType} from 'react-test-renderer';

export type ReactTestInstance = $PropertyType<ReactTestRendererType, 'root'>;

// $FlowFixMe - error revealed when flow-typing ReactTestRenderer
export type Predicate = (node: ReactTestInstance) => boolean;

type $ReturnType<Fn> = $Call<<Ret, A>((...A) => Ret) => Ret, Fn>;
// $FlowFixMe - error revealed when flow-typing ReactTestRenderer
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when Flow
* v0.120 was deployed. To see the error, delete this comment and run Flow. */
export type ReactTestRendererJSON = $ReturnType<ReactTestRenderer.create.toJSON>;

const {
Expand All @@ -53,8 +54,13 @@ function byClickable(): Predicate {
// HACK: Find components that use `Pressability`.
node.instance?.state?.pressability != null ||
// TODO: Remove this after deleting `Touchable`.
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when Flow
* v0.120 was deployed. To see the error, delete this comment and run
* Flow. */
(node.instance &&
// $FlowFixMe - error revealed when flow-typing ReactTestRenderer
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when
* Flow v0.120 was deployed. To see the error, delete this comment and
* run Flow. */
typeof node.instance.touchableHandlePress === 'function'),
'is clickable',
);
Expand All @@ -69,6 +75,9 @@ function byTestID(testID: string): Predicate {

function byTextMatching(regex: RegExp): Predicate {
return withMessage(
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when Flow
* v0.120 was deployed. To see the error, delete this comment and run Flow.
*/
node => node.props && regex.exec(node.props.children),
`text content matches ${regex.toString()}`,
);
Expand Down
2 changes: 0 additions & 2 deletions jest/preprocessor.js
Original file line number Diff line number Diff line change
Expand Up @@ -40,8 +40,6 @@ module.exports = {
}).code;
}

/* $FlowFixMe(>=0.99.0 site=react_native_fb) This fixme can be removed after metro releases
* 0.58 and RN upgrades its dependency */
const {ast} = transformer.transform({
filename: file,
options: {
Expand Down
3 changes: 2 additions & 1 deletion jest/renderer.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,8 @@ const React = require('react');
const ShallowRenderer = require('react-test-renderer/shallow');
const TestRenderer = require('react-test-renderer');

// $FlowFixMe - error revealed when flow-typing ReactTestRenderer
/* $FlowFixMe(>=0.120.0) This comment suppresses an error found when Flow
* v0.120 was deployed. To see the error, delete this comment and run Flow. */
const renderer = new ShallowRenderer();

export const shallow = (Component: React.Element<any>): any => {
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -138,7 +138,7 @@
"eslint-plugin-react-hooks": "^2.0.1",
"eslint-plugin-react-native": "3.8.1",
"eslint-plugin-relay": "1.7.0",
"flow-bin": "^0.119.1",
"flow-bin": "^0.120.1",
"flow-remove-types": "1.2.3",
"jest": "^24.9.0",
"jest-junit": "^6.3.0",
Expand Down
2 changes: 1 addition & 1 deletion template/_flowconfig
Original file line number Diff line number Diff line change
Expand Up @@ -70,4 +70,4 @@ untyped-import
untyped-type-import

[version]
^0.119.0
^0.120.0
8 changes: 4 additions & 4 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -3549,10 +3549,10 @@ flat-cache@^1.2.1:
rimraf "~2.6.2"
write "^0.2.1"

flow-bin@^0.119.1:
version "0.119.1"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.119.1.tgz#b6d763b386ec9f1085848ca7df98909d80a16bd0"
integrity sha512-mX6qjJVi7aLqR9sDf8QIHt8yYEWQbkMLw7qFoC7sM/AbJwvqFm3pATPN96thsaL9o1rrshvxJpSgoj1PJSC3KA==
flow-bin@^0.120.1:
version "0.120.1"
resolved "https://registry.yarnpkg.com/flow-bin/-/flow-bin-0.120.1.tgz#ab051d6df71829b70a26a2c90bb81f9d43797cae"
integrity sha512-KgE+d+rKzdXzhweYVJty1QIOOZTTbtnXZf+4SLnmArLvmdfeLreQOZpeLbtq5h79m7HhDzX/HkUkoyu/fmSC2A==

flow-parser@0.*:
version "0.89.0"
Expand Down

0 comments on commit 1beef1e

Please sign in to comment.