mirror of
https://github.com/ant-design/ant-design.git
synced 2025-01-18 14:13:37 +08:00
test: fix cov (#41214)
This commit is contained in:
parent
571224efa1
commit
989d033978
@ -118,7 +118,12 @@ describe('Modal', () => {
|
||||
});
|
||||
|
||||
it('should not render footer if null', () => {
|
||||
const { container } = render(<Modal footer={null} />);
|
||||
expect(container.querySelector('.ant-modal-footer')).toBeFalsy();
|
||||
render(<Modal open footer={null} />);
|
||||
expect(document.querySelector('.ant-modal-footer')).toBeFalsy();
|
||||
});
|
||||
|
||||
it('should render custom footer', () => {
|
||||
render(<Modal open footer={<div className="custom-footer">footer</div>} />);
|
||||
expect(document.querySelector('.custom-footer')).toBeTruthy();
|
||||
});
|
||||
});
|
||||
|
Loading…
Reference in New Issue
Block a user