diff --git a/features/admin/login.feature b/features/admin/login.feature index b50ce1a3..09ef66ab 100644 --- a/features/admin/login.feature +++ b/features/admin/login.feature @@ -6,16 +6,28 @@ Feature: Login Background: Given I have the site: "test site" set up -Scenario: Successful authentication +Scenario: Successfully logging in When I go to login And I fill in "Email" with "admin@locomotiveapp.org" And I fill in "Password" with "easyone" And I press "Log in" Then I should see "Listing pages" -Scenario: Failed authentication +Scenario: Attempting to login with an invalid emai or password When I go to login And I fill in "Email" with "admin@locomotiveapp.org" And I fill in "Password" with "" And I press "Log in" - Then I should not see "Listing pages" \ No newline at end of file + Then I should not see "Listing pages" + And I should see "Invalid email or password" + +Scenario: Attempting to login with an account without a membership + Given the following accounts exist: + | email | password | password_confirmation | + | john@locomotiveapp.org | bluecheese | bluecheese | + When I go to login + And I fill in "Email" with "john@locomotiveapp.org" + And I fill in "Password" with "bluecheese" + And I press "Log in" + Then I should not see "Listing pages" + And I should see "not a member of this site"