Why do I get this?
Failure/Error: fill_in "Email address",with: "person@example.com"
Capybara::ElementNotFound:
cannot fill in, no text field, text area or password field with id, name, or label 'Email address' found
even though I have this
<%= form_for :session,url: session_path do |f|%>
<%= f.label :email_address %>
<%= f.text_field "email_address "%>
<%= f.submit "Sign In"%>
<% end %>
require ‘spec_helper’
feature "Sign in as a user" do
scenario "with an email address" do
visit root_path
fill_in "Email address",with: "person@example.com"
click_button "Sign In"
expect(page).to have_css ".welcome",text: "Signed in as person@example.com"
end
end