diff --git a/spec/system/admin/authentication_spec.rb b/spec/system/admin/authentication_spec.rb index 8cf5fd8c11..d83e2a3f7d 100644 --- a/spec/system/admin/authentication_spec.rb +++ b/spec/system/admin/authentication_spec.rb @@ -26,4 +26,18 @@ describe "Authentication" do click_link "Account" expect(page).to have_current_path spree.account_path end + + context "logged in" do + before do + login_as user + visit root_path + end + + it "logs out" do + page.find("li", class: "user-menu").click + click_on "Logout" + expect(page).to have_content "Signed out successfully." + expect(page).to have_content "Login" + end + end end