diff options
| author | Armand Philippot <git@armandphilippot.com> | 2023-11-14 12:39:09 +0100 |
|---|---|---|
| committer | Armand Philippot <git@armandphilippot.com> | 2023-11-14 12:50:32 +0100 |
| commit | 50f1c501a87ef5f5650750dbeca797e833ec7c3a (patch) | |
| tree | f1f55092696c7261eaa7f9f9a9338253ede65c2b /src/components/organisms/widgets/sharing.test.tsx | |
| parent | fb29b0f017fae162ffa7ad6bdfc80099346802de (diff) | |
refactor(components): replace Sharing with SharingWidget component
* all the widgets should have a coherent name
* fix mailto uri
* remove useless CSS
* add tests
Diffstat (limited to 'src/components/organisms/widgets/sharing.test.tsx')
| -rw-r--r-- | src/components/organisms/widgets/sharing.test.tsx | 24 |
1 files changed, 0 insertions, 24 deletions
diff --git a/src/components/organisms/widgets/sharing.test.tsx b/src/components/organisms/widgets/sharing.test.tsx deleted file mode 100644 index c7211f0..0000000 --- a/src/components/organisms/widgets/sharing.test.tsx +++ /dev/null @@ -1,24 +0,0 @@ -import { describe, expect, it } from '@jest/globals'; -import { render, screen as rtlScreen } from '../../../../tests/utils'; -import { Sharing, type SharingData } from './sharing'; - -const postData: SharingData = { - excerpt: 'A post excerpt', - title: 'A post title', - url: 'https://sharing-website.test', -}; - -describe('Sharing', () => { - it('renders a sharing widget', () => { - render(<Sharing data={postData} media={['facebook', 'twitter']} />); - expect( - rtlScreen.getByRole('link', { name: 'Share on Facebook' }) - ).toBeInTheDocument(); - expect( - rtlScreen.getByRole('link', { name: 'Share on Twitter' }) - ).toBeInTheDocument(); - expect( - rtlScreen.queryByRole('link', { name: 'Share on LinkedIn' }) - ).not.toBeInTheDocument(); - }); -}); |
