diff --git a/features/login.feature b/features/login.feature index 580c411..fe66e72 100644 --- a/features/login.feature +++ b/features/login.feature @@ -207,3 +207,18 @@ Feature: login | Password | 123456 | When I press "Log in" Then I should be on joaosilva's control panel + + Scenario: join community on login + Given the following users + | login | name | + | mariasilva | Maria Silva | + And the following communities + | name | identifier | owner | + | Free Software | freesoftware | mariasilva | + And I am on /freesoftware + When I follow "Join" + And I fill in the following: + | Username / Email | joaosilva | + | Password | 123456 | + And I press "Log in" + Then "Joao Silva" should be a member of "Free Software" diff --git a/features/signup.feature b/features/signup.feature index 662ee0b..c95c692 100644 --- a/features/signup.feature +++ b/features/signup.feature @@ -250,3 +250,51 @@ Feature: signup And I fill in "Password" with "secret" And I press "Log in" Then I should be on the homepage + + @selenium + Scenario: join community on signup + Given the following users + | login | name | + | mariasilva | Maria Silva | + And the following communities + | name | identifier | owner | + | Free Software | freesoftware | mariasilva | + And feature "skip_new_user_email_confirmation" is disabled on environment + And I am on /freesoftware + When I follow "Join" + And I follow "New user" + And I fill in the following within ".no-boxes": + | e-Mail | josesilva@example.com | + | Username | josesilva | + | Password | secret | + | Password confirmation | secret | + | Full name | José da Silva | + And wait for the captcha signup time + And I press "Create my account" + And I go to josesilva's confirmation URL + And I fill in "Username" with "josesilva" + And I fill in "Password" with "secret" + And I press "Log in" + Then "Joao Silva" should be a member of "Free Software" + + @selenium + Scenario: join community on direct signup + Given the following users + | login | name | + | mariasilva | Maria Silva | + And the following communities + | name | identifier | owner | + | Free Software | freesoftware | mariasilva | + And feature "skip_new_user_email_confirmation" is enabled on environment + And I am on /freesoftware + When I follow "Join" + And I follow "New user" + And I fill in the following within ".no-boxes": + | e-Mail | josesilva@example.com | + | Username | josesilva | + | Password | secret | + | Password confirmation | secret | + | Full name | José da Silva | + And wait for the captcha signup time + And I press "Create my account" + Then "Joao Silva" should be a member of "Free Software" -- libgit2 0.21.2