diff --git a/packages/react-native/Libraries/LogBox/UI/__tests__/LogBoxInspectorSourceMapStatus-test.js b/packages/react-native/Libraries/LogBox/UI/__tests__/LogBoxInspectorSourceMapStatus-test.js index 940efb2580f..f9ca446de36 100644 --- a/packages/react-native/Libraries/LogBox/UI/__tests__/LogBoxInspectorSourceMapStatus-test.js +++ b/packages/react-native/Libraries/LogBox/UI/__tests__/LogBoxInspectorSourceMapStatus-test.js @@ -16,9 +16,16 @@ const LogBoxInspectorSourceMapStatus = require('../LogBoxInspectorSourceMapStatus').default; const React = require('react'); +// Mock `LogBoxButton` because we are interested in snapshotting the behavior +// of `LogBoxInspectorSourceMapStatus`, not `LogBoxButton`. +jest.mock('../LogBoxButton', () => ({ + __esModule: true, + default: 'LogBoxButton', +})); + describe('LogBoxInspectorSourceMapStatus', () => { it('should render for failed', () => { - const output = render.shallowRender( + const output = render.create( {}} status="FAILED" />, ); @@ -26,7 +33,7 @@ describe('LogBoxInspectorSourceMapStatus', () => { }); it('should render for pending', () => { - const output = render.shallowRender( + const output = render.create( {}} status="PENDING" />, ); @@ -34,7 +41,7 @@ describe('LogBoxInspectorSourceMapStatus', () => { }); it('should render null for complete', () => { - const output = render.shallowRender( + const output = render.create( {}} status="COMPLETE" />, ); diff --git a/packages/react-native/Libraries/LogBox/UI/__tests__/__snapshots__/LogBoxInspectorSourceMapStatus-test.js.snap b/packages/react-native/Libraries/LogBox/UI/__tests__/__snapshots__/LogBoxInspectorSourceMapStatus-test.js.snap index 612a75000e4..df2fcc92128 100644 --- a/packages/react-native/Libraries/LogBox/UI/__tests__/__snapshots__/LogBoxInspectorSourceMapStatus-test.js.snap +++ b/packages/react-native/Libraries/LogBox/UI/__tests__/__snapshots__/LogBoxInspectorSourceMapStatus-test.js.snap @@ -27,25 +27,20 @@ exports[`LogBoxInspectorSourceMapStatus should render for failed 1`] = ` } } > - -