specs: ensure the procedure-less sign-up is tested
This commit is contained in:
parent
e2356c8000
commit
dcc81d42dd
1 changed files with 3 additions and 4 deletions
|
@ -5,16 +5,15 @@ feature 'Signing up:' do
|
||||||
let(:user_password) { 'démarches-simplifiées-pwd' }
|
let(:user_password) { 'démarches-simplifiées-pwd' }
|
||||||
let(:procedure) { create :simple_procedure, :with_service }
|
let(:procedure) { create :simple_procedure, :with_service }
|
||||||
|
|
||||||
scenario 'a new user can sign-up' do
|
scenario 'a new user can sign-up from scratch' do
|
||||||
visit commencer_path(path: procedure.path)
|
visit new_user_registration_path
|
||||||
click_on 'Créer un compte demarches-simplifiees.fr'
|
|
||||||
|
|
||||||
sign_up_with user_email, user_password
|
sign_up_with user_email, user_password
|
||||||
expect(page).to have_content "nous avons besoin de vérifier votre adresse #{user_email}"
|
expect(page).to have_content "nous avons besoin de vérifier votre adresse #{user_email}"
|
||||||
|
|
||||||
click_confirmation_link_for user_email
|
click_confirmation_link_for user_email
|
||||||
expect(page).to have_content 'Votre compte a été activé'
|
expect(page).to have_content 'Votre compte a été activé'
|
||||||
expect(page).to have_current_path commencer_path(path: procedure.path)
|
expect(page).to have_current_path dossiers_path
|
||||||
end
|
end
|
||||||
|
|
||||||
context 'when the user makes a typo in their email address' do
|
context 'when the user makes a typo in their email address' do
|
||||||
|
|
Loading…
Reference in a new issue