joegasewicz / react-bare-forms

A bare minimal React form library for quick & simple forms.
https://joegasewicz.github.io/react-bare-forms/
MIT License
20 stars 4 forks source link

TestingLibraryElementError: Found a label with the text of: Email, however no form control was found associated to that label #124

Open joegasewicz opened 3 years ago

joegasewicz commented 3 years ago

This is failing due to no for attribute on lables. A Fix would be to reference the name of the text input:

React testing library Error:

TestingLibraryElementError: Found a label with the text of: Email, however no form control was found associated to that label

from https://www.w3schools.com/tags/tag_label.asp

<label for="male">Male</label>