]> git.r.bdr.sh - rbdr/forum/blame_incremental - src/components/actions/topic.test.js
Add getForum pact, normalize stores
[rbdr/forum] / src / components / actions / topic.test.js
... / ...
CommitLineData
1import '@testing-library/jest-dom/extend-expect';
2
3import { render } from '@testing-library/svelte';
4import '$/config/i18n';
5
6import Topic from './topic.svelte';
7
8const internals = {
9 results: null
10};
11
12describe('Topic Actions component', () => {
13
14 test('Should link to reply page', () => {
15
16 const results = render(Topic, { props: {
17 actions: {
18 id: '8ebaa211-fd9b-423a-8b4f-b57622007fde'
19 }
20 } });
21
22 expect(results.getByTitle('Reply').closest('a'))
23 .toHaveAttribute('href', '/reply/8ebaa211-fd9b-423a-8b4f-b57622007fde');
24 });
25});