Skip to content

Commit

Permalink
s/ReactDOMX/ReactDOM
Browse files Browse the repository at this point in the history
  • Loading branch information
rickhanlonii committed Jan 26, 2024
1 parent c43d853 commit c98cac9
Showing 1 changed file with 23 additions and 23 deletions.
46 changes: 23 additions & 23 deletions packages/react-dom/src/__tests__/ReactCompositeComponent-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
let ChildUpdates;
let MorphingComponent;
let React;
let ReactDOMX;
let ReactDOM;
let ReactDOMClient;
let ReactCurrentOwner;
let Scheduler;
Expand Down Expand Up @@ -65,7 +65,7 @@ describe('ReactCompositeComponent', () => {
beforeEach(() => {
jest.resetModules();
React = require('react');
ReactDOMX = require('react-dom');
ReactDOM = require('react-dom');
ReactDOMClient = require('react-dom/client');
ReactCurrentOwner =
require('react').__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED
Expand Down Expand Up @@ -225,7 +225,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(el);
expect(() => {
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Child test="test" />);
});
}).toThrow(
Expand Down Expand Up @@ -254,7 +254,7 @@ describe('ReactCompositeComponent', () => {
const el = document.createElement('div');
const root = ReactDOMClient.createRoot(el);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Child test="test" />);
});
}).toErrorDev(
Expand Down Expand Up @@ -336,7 +336,7 @@ describe('ReactCompositeComponent', () => {
const container = document.createElement('div');
const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<MyComponent />);
});
}).toErrorDev(
Expand Down Expand Up @@ -370,7 +370,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(container);

expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<MyComponent />);
});
}).toErrorDev(
Expand Down Expand Up @@ -506,7 +506,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(container);
expect(() => {
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<ClassWithRenderNotExtended />);
});
}).toThrow(TypeError);
Expand All @@ -518,7 +518,7 @@ describe('ReactCompositeComponent', () => {

// Test deduplication
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<ClassWithRenderNotExtended />);
});
}).toThrow(TypeError);
Expand All @@ -542,7 +542,7 @@ describe('ReactCompositeComponent', () => {
let instance;
const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Component ref={ref => (instance = ref)} />);
});
}).toErrorDev(
Expand Down Expand Up @@ -575,7 +575,7 @@ describe('ReactCompositeComponent', () => {

const root = ReactDOMClient.createRoot(document.createElement('div'));
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(instance);
});
}).toThrow();
Expand Down Expand Up @@ -635,7 +635,7 @@ describe('ReactCompositeComponent', () => {
});

expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
instance.setState({bogus: true});
});
}).toErrorDev(
Expand All @@ -655,7 +655,7 @@ describe('ReactCompositeComponent', () => {

const root = ReactDOMClient.createRoot(document.createElement('div'));
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Component />);
});
}).toErrorDev(
Expand All @@ -677,7 +677,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(document.createElement('div'));

expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Component />);
});
}).toErrorDev(
Expand All @@ -703,7 +703,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(document.createElement('div'));

expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Component />);
});
}).toErrorDev(
Expand Down Expand Up @@ -756,7 +756,7 @@ describe('ReactCompositeComponent', () => {
}

expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Outer />);
});
}).toErrorDev(
Expand Down Expand Up @@ -853,7 +853,7 @@ describe('ReactCompositeComponent', () => {

const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Foo idx="qwe" />);
});
}).toErrorDev(
Expand Down Expand Up @@ -898,10 +898,10 @@ describe('ReactCompositeComponent', () => {

const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<App ref={setRef} stage={1} />);
});
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<App ref={setRef} stage={2} />);
});
}).toThrow();
Expand Down Expand Up @@ -1204,7 +1204,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(document.createElement('div'));
expect(() => {
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<RenderTextInvalidConstructor />);
});
}).toThrow();
Expand Down Expand Up @@ -1236,7 +1236,7 @@ describe('ReactCompositeComponent', () => {
const container = document.createElement('div');
const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Bad />);
});
}).toErrorDev(
Expand All @@ -1251,7 +1251,7 @@ describe('ReactCompositeComponent', () => {
const root = ReactDOMClient.createRoot(document.createElement('div'));
expect(() => {
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<RenderTestUndefinedRender />);
});
}).toThrow();
Expand Down Expand Up @@ -1420,7 +1420,7 @@ describe('ReactCompositeComponent', () => {
const container = document.createElement('div');
const root = ReactDOMClient.createRoot(container);
expect(() => {
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Parent />);
});
}).toErrorDev(
Expand All @@ -1431,7 +1431,7 @@ describe('ReactCompositeComponent', () => {
expect(ref.textContent).toBe('1');

// Dedupe.
ReactDOMX.flushSync(() => {
ReactDOM.flushSync(() => {
root.render(<Parent />);
});

Expand Down

0 comments on commit c98cac9

Please sign in to comment.