From 12a03a9a72f7895d571dbaeeb245d92aa277a610 Mon Sep 17 00:00:00 2001 From: Armand Philippot Date: Fri, 6 Oct 2023 17:48:03 +0200 Subject: refactor(components): merge HeadingButton and Widget components The HeadingButton component was only used inside Widget component and it is not very useful on its own so I merge the two components in a new Collapsible component. --- src/components/molecules/layout/widget.test.tsx | 20 -------------------- 1 file changed, 20 deletions(-) delete mode 100644 src/components/molecules/layout/widget.test.tsx (limited to 'src/components/molecules/layout/widget.test.tsx') diff --git a/src/components/molecules/layout/widget.test.tsx b/src/components/molecules/layout/widget.test.tsx deleted file mode 100644 index 21c7a3c..0000000 --- a/src/components/molecules/layout/widget.test.tsx +++ /dev/null @@ -1,20 +0,0 @@ -import { describe, expect, it } from '@jest/globals'; -import { render, screen } from '../../../../tests/utils'; -import { Widget } from './widget'; - -const children = 'Widget body'; -const title = 'Widget title'; -const titleLevel = 2; - -describe('Widget', () => { - it('renders the widget title', () => { - render( - - {children} - - ); - expect( - screen.getByRole('heading', { level: titleLevel }) - ).toHaveTextContent(title); - }); -}); -- cgit v1.2.3