40 lines
761 B
TypeScript
40 lines
761 B
TypeScript
|
import '@testing-library/jest-dom';
|
||
|
import { render, screen } from '@testing-library/svelte';
|
||
|
|
||
|
import BlockOrReport from '../../../src/lib/components/atoms/BlockOrReport.svelte';
|
||
|
|
||
|
describe('BlockOrReport.svelte', () => {
|
||
|
it('should mount', () => {
|
||
|
// Arrange
|
||
|
// Nothing to prepare
|
||
|
|
||
|
// Act
|
||
|
const { container } = render(BlockOrReport);
|
||
|
|
||
|
// Assert
|
||
|
expect(container).toBeTruthy();
|
||
|
});
|
||
|
|
||
|
it('should allow for block', () => {
|
||
|
// Arrange
|
||
|
// Nothing to prepare
|
||
|
|
||
|
// Act
|
||
|
render(BlockOrReport);
|
||
|
|
||
|
// Assert
|
||
|
expect(screen.getByText('block')).toBeDefined();
|
||
|
});
|
||
|
|
||
|
it('should allow for report', () => {
|
||
|
// Arrange
|
||
|
// Nothing to prepare
|
||
|
|
||
|
// Act
|
||
|
render(BlockOrReport);
|
||
|
|
||
|
// Assert
|
||
|
expect(screen.getByText('report')).toBeDefined();
|
||
|
});
|
||
|
});
|