import React from 'react'; import { customRender } from 'test-utils'; import { Icon } from '@lightspeed/flame/Icon'; import { Sidebar, SidebarHeader, SidebarAppSwitcher, SidebarShopButton, SidebarDropdownButton, SidebarAccountDropdown, SidebarMenu, SidebarMenuItem, SidebarItem, SidebarNotificationBadge, SidebarNav, SidebarFooter, SidebarFooterItem, } from '.'; const items = [ { icon: , children: 'Home', href: '/', active: true }, { icon: , children: 'Item with notifications', href: 'orders', hasSublevel: true, notifications: 2, }, { icon: , children: 'Item with onClick', href: 'blogs', onClick: (e: React.MouseEvent) => { e.preventDefault(); }, hasSublevel: true, }, { icon: , children: 'Item with disabled', href: 'some-route', disabled: true, }, ]; const sidebar: React.FC<{ isAccountMenuOpen: boolean }> = ({ isAccountMenuOpen }) => ( SidebarShopButton Content ( Awesome Merchant )} > Tasks My Account Logout {items.map(item => ( ))} } href="#" target="_blank" rel="noopener noreferrer" > Help } href="#" target="_blank" rel="noopener noreferrer" > Search ); describe('', () => { it('should render', () => { const { container } = customRender(sidebar({ isAccountMenuOpen: false })); expect(container).not.toBeUndefined(); }); });