mirror of
https://github.com/facebook/react-native.git
synced 2025-11-01 09:14:26 +00:00
Add tests for Modal.statusBarTranslucent prop (#53158)
Summary: Pull Request resolved: https://github.com/facebook/react-native/pull/53158 Add Fantom tests for Modal.statusBarTranslucent prop ## Changelog: [Internal] - Reviewed By: andrewdacenko Differential Revision: D79881104 fbshipit-source-id: 9ee9edbff67059eeb815be2a7a095eac91ec7420
This commit is contained in:
committed by
Facebook GitHub Bot
parent
99ae977345
commit
de76f3436c
@@ -154,6 +154,39 @@ describe('<Modal>', () => {
|
||||
);
|
||||
});
|
||||
});
|
||||
describe('statusBarTranslucent', () => {
|
||||
it('renders a Modal with statusBarTranslucent="true"', () => {
|
||||
const root = Fantom.createRoot();
|
||||
|
||||
Fantom.runTask(() => {
|
||||
root.render(<Modal statusBarTranslucent={true} />);
|
||||
});
|
||||
|
||||
expect(
|
||||
root.getRenderedOutput({props: ['statusBarTranslucent']}).toJSX(),
|
||||
).toEqual(
|
||||
<rn-modalHostView statusBarTranslucent="true">
|
||||
<rn-view />
|
||||
</rn-modalHostView>,
|
||||
);
|
||||
});
|
||||
it('renders a Modal with statusBarTranslucent="false"', () => {
|
||||
const root = Fantom.createRoot();
|
||||
|
||||
Fantom.runTask(() => {
|
||||
root.render(<Modal statusBarTranslucent={false} />);
|
||||
});
|
||||
|
||||
expect(
|
||||
root.getRenderedOutput({props: ['statusBarTranslucent']}).toJSX(),
|
||||
).toEqual(
|
||||
<rn-modalHostView>
|
||||
<rn-view />
|
||||
</rn-modalHostView>,
|
||||
);
|
||||
});
|
||||
});
|
||||
|
||||
// ... more props
|
||||
});
|
||||
describe('ref', () => {
|
||||
|
||||
Reference in New Issue
Block a user