Introduce capybara and first feature spec (#1801)
This commit introduces Capybara and the first feature spec.
I focused on coverage for log in for the first feature spec because that would
have prevented a1c63cb01d
causing #1236.
th-downstream
parent
20170cb4f3
commit
29f169f7f0
@ -0,0 +1,16 @@
|
||||
require "rails_helper"
|
||||
|
||||
feature "Log in" do
|
||||
scenario "A valid email and password user is able to log in" do
|
||||
email = "test@example.com"
|
||||
password = "password"
|
||||
Fabricate(:user, email: email, password: password)
|
||||
|
||||
visit new_user_session_path
|
||||
fill_in "user_email", with: email
|
||||
fill_in "user_password", with: password
|
||||
click_on "Log in"
|
||||
|
||||
expect(page).to have_css "div.app-holder[data-react-class=Mastodon]"
|
||||
end
|
||||
end
|
Loading…
Reference in new issue