What's the best way to test the front end of your application?

For example if one page of the application is a form for the user to fill out. I want to test inputting a bunch of data on the form, and then check the database so that the expected data is there at the end. Or if a user goes to the registration page and fills out the form to create a new account, I want to test that the new account with the expected input data is now in the database. Is there a tool that will fill out the relevant data and click the appropriate buttons, and that will also do it in the test environment?

What’s the right way to test this?

If you want to test the whole page, you’ll want to use an End to End testing tool like Chimp, Cypress, Puppeteer, SlimerJS, etc.

What they do is run a full browser instance and then execute the tests you have specified.
I recommend you check out some of the tools or search for End to End testing guides

1 Like