The Third Test: Fill and Submit Form
Explore how to write feature tests for filling and submitting forms in Ruby on Rails. Understand the importance of test-first development as you identify and resolve issues such as missing form fields, controllers, and routes. This lesson helps you ensure your application behaves as expected by using tests to guide development and catch errors early.
We'll cover the following...
We'll cover the following...
Setting up the test
Our third step is "I fill in and submit the registration form".
Considering what the step needs to accomplish, the code below illustrates how a user might complete that step:
Looking good. That’s what we imagine the user doing when they fill in the ...