Skip to content

Commit 06edbaf

Browse files
committed
add test
1 parent c16fb4a commit 06edbaf

File tree

1 file changed

+27
-0
lines changed

1 file changed

+27
-0
lines changed

src/wallet/components/WalletAdvancedContent.test.tsx

+27
Original file line numberDiff line numberDiff line change
@@ -410,4 +410,31 @@ describe('WalletAdvancedContent', () => {
410410

411411
expect(screen.getByTestId('ockBottomSheet')).toBeDefined();
412412
});
413+
414+
it('applies custom classNames to BottomSheet when breakpoint is sm', () => {
415+
mockUseWalletContext.mockReturnValue({
416+
isSubComponentOpen: true,
417+
breakpoint: 'sm',
418+
});
419+
420+
mockUseWalletAdvancedContext.mockReturnValue({
421+
...defaultMockUseWalletAdvancedContext,
422+
showQr: true,
423+
showSwap: false,
424+
});
425+
426+
const customClassNames = {
427+
container: 'custom-container',
428+
};
429+
430+
render(
431+
<WalletAdvancedContent classNames={customClassNames}>
432+
<div>Content</div>
433+
</WalletAdvancedContent>,
434+
);
435+
436+
expect(screen.getByTestId('ockBottomSheet')).toHaveClass(
437+
'custom-container',
438+
);
439+
});
413440
});

0 commit comments

Comments
 (0)