Ringtone app
Non puoi selezionare più di 25 argomenti Gli argomenti devono iniziare con una lettera o un numero, possono includere trattini ('-') e possono essere lunghi fino a 35 caratteri.
 
 
 

16 righe
473 B

  1. import {render, screen} from '@testing-library/react'
  2. import TextInput from '.'
  3. describe('single-line text input component', () => {
  4. it('should contain a text input element', () => {
  5. render(<TextInput label="" name="" />)
  6. expect(screen.getByRole('textbox')).toBeInTheDocument()
  7. })
  8. it('should acquire a descriptive label', () => {
  9. const label = 'foo'
  10. render(<TextInput label={label} name="" />)
  11. expect(screen.getByLabelText(label)).toBeInTheDocument()
  12. })
  13. })