]>
git.r.bdr.sh - rbdr/forum/blob - src/components/actions/topic.test.js
1 import '@testing-library/jest-dom/extend-expect';
3 import { render
} from '@testing-library/svelte';
4 import '$/config/i18n';
6 import Topic
from './topic.svelte';
12 describe('Topic Actions component', () => {
14 test('Should link to reply page', () => {
16 const results
= render(Topic
, { props: {
18 id: '8ebaa211-fd9b-423a-8b4f-b57622007fde'
22 expect(results
.getByTitle('Reply').closest('a'))
23 .toHaveAttribute('href', '/reply/8ebaa211-fd9b-423a-8b4f-b57622007fde');