Skip to content

Commit fc40ae0

Browse files
committed
test: fill coverage
1 parent bfdd9c7 commit fc40ae0

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

tests/previewGroup.test.tsx

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -413,4 +413,22 @@ describe('PreviewGroup', () => {
413413
action: 'next',
414414
});
415415
});
416+
417+
it('preview.rootClassName should be correct', () => {
418+
render(
419+
<Image.PreviewGroup
420+
items={[
421+
{
422+
src: 'src1',
423+
},
424+
]}
425+
preview={{
426+
open: true,
427+
rootClassName: 'custom-className',
428+
}}
429+
/>,
430+
);
431+
432+
expect(document.querySelector('.rc-image-preview.custom-className')).toBeTruthy();
433+
});
416434
});

0 commit comments

Comments
 (0)