diff --git a/spec/features/locale_spec.rb b/spec/features/locale_spec.rb index dd912f5e8..2dce809ad 100644 --- a/spec/features/locale_spec.rb +++ b/spec/features/locale_spec.rb @@ -8,6 +8,7 @@ describe "Changing locales", js: true do # Login then log out, to ensure we're now logged out login_as member visit root_path + click_link member.login_name click_link 'Sign out' expect(page).to have_content("a community of food gardeners.") visit root_path(locale: 'ja') diff --git a/spec/features/signin_spec.rb b/spec/features/signin_spec.rb index 55e31d4b9..9ff9304fc 100644 --- a/spec/features/signin_spec.rb +++ b/spec/features/signin_spec.rb @@ -15,6 +15,7 @@ describe "signin", js: true do visit crops_path # some random page click_link 'Sign in' login + click_link member.login_name expect(page).to have_content("Sign out") end diff --git a/spec/features/signout_spec.rb b/spec/features/signout_spec.rb index d65370ff6..82b3363c2 100644 --- a/spec/features/signout_spec.rb +++ b/spec/features/signout_spec.rb @@ -9,6 +9,7 @@ describe "signout" do fill_in 'Login', with: member.login_name fill_in 'Password', with: member.password click_button 'Sign in' + click_link member.login_name click_link 'Sign out' expect(current_path).to eq crops_path end @@ -23,7 +24,8 @@ describe "signout" do click_button 'Sign in' # expect(page).to have_http_status(200) expect(current_path).to eq path - click_link 'Sign out' + click_link member.login_name + click_link 'Sign out' # expect(page).to have_http_status(200) expect(current_path).to eq new_member_session_path end