Skip to content

Commit

Permalink
Back out ""React Native sync for revisions b5c6dd2...a437f3ff3""
Browse files Browse the repository at this point in the history
Summary:
Original commit changeset: c3c146b87fa5

Changelog: [Internal]

Reviewed By: makovkastar

Differential Revision: D22949053

fbshipit-source-id: 746719e44cd5d960dc14d7398f093a288ab61d88
  • Loading branch information
rickhanlonii authored and facebook-github-bot committed Aug 5, 2020
1 parent 065fbe3 commit 4cdb195
Show file tree
Hide file tree
Showing 13 changed files with 34,654 additions and 38,514 deletions.
5 changes: 1 addition & 4 deletions Libraries/LogBox/__tests__/LogBox-integration-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,10 +49,7 @@ const cleanLog = logs => {
});
};

// TODO(T71117418): Re-enable skipped LogBox integration tests once React component
// stack frames are the same internally and in open source.
// eslint-disable-next-line jest/no-disabled-tests
describe.skip('LogBox', () => {
describe('LogBox', () => {
const {error, warn} = console;
const mockError = jest.fn();
const mockWarn = jest.fn();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,94 @@
// Jest Snapshot v1, https://goo.gl/fbAQLP

exports[`LogBox integrates with React and handles a fragment warning in LogBox: Log added to LogBox 1`] = `
Array [
Object {
"category": "Warning: Invalid prop \`%s\` supplied to \`React.Fragment\`. React.Fragment can only have \`key\` and \`children\` props.",
"componentStack": Array [
Object {
"content": "Fragment",
"fileName": "ReactWarningFixtures.js",
"location": Object {
"column": -1,
"row": 28,
},
},
],
"level": "warn",
"message": Object {
"content": "Warning: Invalid prop \`invalid\` supplied to \`React.Fragment\`. React.Fragment can only have \`key\` and \`children\` props.",
"substitutions": Array [
Object {
"length": 7,
"offset": 23,
},
],
},
},
]
`;

exports[`LogBox integrates with React and handles a fragment warning in LogBox: Log passed to console error 1`] = `
Array [
"Warning: Invalid prop \`invalid\` supplied to \`React.Fragment\`. React.Fragment can only have \`key\` and \`children\` props.
in Fragment (at ReactWarningFixtures.js:28)",
]
`;

exports[`LogBox integrates with React and handles a fragment warning in LogBox: Log sent from React 1`] = `
Array [
"Warning: Invalid prop \`%s\` supplied to \`React.Fragment\`. React.Fragment can only have \`key\` and \`children\` props.%s",
"invalid",
"
in Fragment (at ReactWarningFixtures.js:28)",
]
`;

exports[`LogBox integrates with React and handles a key error in LogBox: Log added to LogBox 1`] = `
Array [
Object {
"category": "Warning: Each child in a list should have a unique \\"key\\" prop.%s%s See https://fb.me/react-warning-keys for more information.",
"componentStack": Array [
Object {
"content": "Text",
"fileName": "ReactWarningFixtures.js",
"location": Object {
"column": -1,
"row": 20,
},
},
],
"level": "warn",
"message": Object {
"content": "Warning: Each child in a list should have a unique \\"key\\" prop. See https://fb.me/react-warning-keys for more information.",
"substitutions": Array [
Object {
"length": 0,
"offset": 62,
},
Object {
"length": 0,
"offset": 62,
},
],
},
},
]
`;

exports[`LogBox integrates with React and handles a key error in LogBox: Log passed to console error 1`] = `
Array [
"Warning: Each child in a list should have a unique \\"key\\" prop. See https://fb.me/react-warning-keys for more information.
in Text (at ReactWarningFixtures.js:20)",
]
`;

exports[`LogBox integrates with React and handles a key error in LogBox: Log sent from React 1`] = `
Array [
"Warning: Each child in a list should have a unique \\"key\\" prop.%s%s See https://fb.me/react-warning-keys for more information.%s",
"",
"",
"
in Text (at ReactWarningFixtures.js:20)",
]
`;
2 changes: 1 addition & 1 deletion Libraries/Renderer/REVISION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
a437f3ff302dc92347d812d518c9a9659d9aa546
b5c6dd2de557428974855b5aa88bf9c6595beb2b
Loading

0 comments on commit 4cdb195

Please sign in to comment.