This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| it('Failure test', async () => { | |
| const handleSubmit = jest.fn(); | |
| render(<CompanyForm onSubmit={handleSubmit} />); | |
| const submitButton = screen.getByTestId('companyFormSubmitButton'); | |
| const nameError = screen.getByTestId('nameError'); | |
| const emailError = screen.queryByTestId('emailError'); | |
| const phoneNumberError = screen.queryByTestId('phoneNumberError'); | |
| const agreementError = screen.queryByTestId('agreementError'); |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React from 'react'; | |
| import { render, screen, waitFor } from '@testing-library/react'; | |
| import userEvent from '@testing-library/user-event'; | |
| import formTestConstants from '../../constants/formTest.constants'; | |
| import { CompanyForm } from '../../components/forms/CompanyForm/CompanyForm'; |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| import React from 'react'; | |
| import { render, screen, waitFor } from '@testing-library/react'; | |
| import userEvent from '@testing-library/user-event'; | |
| import formTestConstants from '../../constants/formTest.constants'; | |
| import { CompanyForm } from '../../components/forms/CompanyForm/CompanyForm'; | |
| // testing if company form is working | |
| describe('CompanyForm tests 🙂', () => { | |
| it('Success test', async () => { |
NewerOlder