| Total Complexity | 1 |
| Complexity/F | 1 |
| Lines of Code | 15 |
| Function Count | 1 |
| Duplicated Lines | 0 |
| Ratio | 0 % |
| Changes | 0 | ||
| 1 | import '@testing-library/jest-dom/extend-expect'; |
||
| 2 | import { screen, render } from '@testing-library/svelte'; |
||
| 3 | import Input from './Input.svelte'; |
||
| 4 | |||
| 5 | it('renders an email input.', () => { |
||
| 6 | const value = 'abc'; |
||
| 7 | const label = 'my email input'; |
||
| 8 | const type = 'email'; |
||
| 9 | |||
| 10 | render(Input, { value, label, type }); |
||
| 11 | |||
| 12 | expect( |
||
| 13 | screen.getByRole('textbox', { name: /my email input/i }) |
||
| 14 | ).toBeInTheDocument(); |
||
| 15 | }); |
||
| 16 |