mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2025-09-06 21:24:23 +08:00
fix problem with unconfirmed users
This commit is contained in:
parent
550c5ad6f6
commit
9c3c32a366
2 changed files with 1 additions and 55 deletions
|
@ -1,55 +0,0 @@
|
|||
# feature/sign up.feature
|
||||
Feature: Sign up
|
||||
As a new User
|
||||
I want to Sign up as a new User
|
||||
I want to create a new account
|
||||
|
||||
Background:
|
||||
Given the following users is registered:
|
||||
| email | password | team
|
||||
| nonadmin@myorg.com | mypassword1234 | BioSistemika Process
|
||||
|
||||
Scenario: Successful Sign up
|
||||
Given I am on Sign up page
|
||||
Then I fill the Sign up form with
|
||||
| Full name | Email | Password | Password confirmation | Team name |
|
||||
| Karli | nonuser@myorg.com | mypassword1234 | mypassword1234 | BioSistemika Process |
|
||||
And I click on reCAPTCHA.
|
||||
And I click on "Sign up" button
|
||||
Then I should see "BioSistemika Process"
|
||||
Then I should see "Hi, Karli" nex to the avatar
|
||||
And I should get a Gamification pop up message "Welcome to sciNote."
|
||||
|
||||
Scenario: Unsuccessful Sign up, Password confirmation does not match
|
||||
Given I am on Sign up page
|
||||
Then I fill the Sign up form with
|
||||
| Full name | Email | Password | Password confirmation | Team name |
|
||||
| Karli | nonuser@myorg.com | mypassword1234 | mypassword123344 | BioSistemika Process |
|
||||
And I click on reCAPTCHA.
|
||||
And I click on "Sign up" button
|
||||
Then I should see "doesn't match Password" error message under "Password confirmation" field
|
||||
|
||||
Scenario: Unsuccessful Sign up, Team name is missing
|
||||
Given I am on Sign up page
|
||||
Then I fill the Sign up form with
|
||||
| Full name | Email | Password | Password confirmation |
|
||||
| Karli | nonuser@myorg.com | mypassword1234 | mypassword123344 |
|
||||
And I click on reCAPTCHA.
|
||||
And I click on "Sign up" button
|
||||
Then I should see "is too short (minimum is 2 characters)" error message under "Team name" field
|
||||
|
||||
Scenario: Unsuccessful Sign up, reCAPTCHA is missing
|
||||
Given I am on Sign up page
|
||||
Then I fill the Sign up form with
|
||||
| Full name | Email | Password | Password confirmation | Team name |
|
||||
| Karli | nonuser@myorg.com | mypassword1234 | mypassword1234 | BioSistemika Process |
|
||||
And I click on "Sign up" button
|
||||
Then I should see "reCAPTCHA verification failed, please try again." error message under "recaptcha" field
|
||||
|
||||
Scenario: Unsuccessful Sign up, Email has already been taken
|
||||
Given I am on Sign up page
|
||||
Then I fill the Sign up form with
|
||||
| Full name | Email | Password | Password confirmation | Team name |
|
||||
| Karli | nonadmin@myorg.com | mypassword1234 | mypassword1234 | BioSistemika Process |
|
||||
And I click on "Sign up" button
|
||||
Then I should see "has already been taken" error message under Email field
|
|
@ -1,6 +1,7 @@
|
|||
Given(/^the following users are registered$/) do |table|
|
||||
table.hashes.each do |hash|
|
||||
FactoryGirl.create(:user, hash)
|
||||
User.find_by_email(hash.fetch('email')).confirm
|
||||
end
|
||||
end
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue