Skip to content

Commit

Permalink
Replace import syntax in ReactNativeTestTools
Browse files Browse the repository at this point in the history
Summary:
Changelog:
[Internal] - Replaced React and ReactTestRenderer import syntax in ReactNativeTestTools

Differential Revision: D68205425
  • Loading branch information
coado authored and facebook-github-bot committed Jan 15, 2025
1 parent 559d070 commit 535ca2b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,14 @@ import type {ReactTestRenderer as ReactTestRendererType} from 'react-test-render

import TouchableWithoutFeedback from '../Components/Touchable/TouchableWithoutFeedback';

import React from 'react';
import ReactTestRenderer from 'react-test-renderer';

const Switch = require('../Components/Switch/Switch').default;
const TextInput = require('../Components/TextInput/TextInput');
const View = require('../Components/View/View');
const Text = require('../Text/Text');
const {VirtualizedList} = require('@react-native/virtualized-lists');
const React = require('react');
const ReactTestRenderer = require('react-test-renderer');

export type ReactTestInstance = $PropertyType<ReactTestRendererType, 'root'>;
export type Predicate = (node: ReactTestInstance) => boolean;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -9151,9 +9151,7 @@ declare module.exports: RCTLog;
`;

exports[`public API should not change unintentionally Libraries/Utilities/ReactNativeTestTools.js 1`] = `
"declare const React: $FlowFixMe;
declare const ReactTestRenderer: $FlowFixMe;
export type ReactTestInstance = $PropertyType<ReactTestRendererType, \\"root\\">;
"export type ReactTestInstance = $PropertyType<ReactTestRendererType, \\"root\\">;
export type Predicate = (node: ReactTestInstance) => boolean;
export type ReactTestRendererJSON = ReturnType<ReactTestRenderer.create.toJSON>;
declare function byClickable(): Predicate;
Expand Down

0 comments on commit 535ca2b

Please sign in to comment.