From c52a9791993284999087167c4bc3beb63eec757b Mon Sep 17 00:00:00 2001 From: Mathieu Magnin Date: Thu, 1 Jun 2017 17:44:56 +0200 Subject: [PATCH] Fix email collision in tests --- spec/factories/administrateur.rb | 2 +- spec/factories/gestionnaire.rb | 2 +- spec/factories/user.rb | 2 +- spec/views/admin/gestionnaires/index.html.haml_spec.rb | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spec/factories/administrateur.rb b/spec/factories/administrateur.rb index 05cfc88a2..f81e5a6a9 100644 --- a/spec/factories/administrateur.rb +++ b/spec/factories/administrateur.rb @@ -1,5 +1,5 @@ FactoryGirl.define do - sequence(:administrateur_email) { |n| "plop#{n}@plop.com" } + sequence(:administrateur_email) { |n| "admin#{n}@admin.com" } factory :administrateur do email { generate(:administrateur_email) } password 'password' diff --git a/spec/factories/gestionnaire.rb b/spec/factories/gestionnaire.rb index 88043eecf..02ee8d5eb 100644 --- a/spec/factories/gestionnaire.rb +++ b/spec/factories/gestionnaire.rb @@ -1,5 +1,5 @@ FactoryGirl.define do - sequence(:gestionnaire_email) { |n| "gest#{n}@plop.com" } + sequence(:gestionnaire_email) { |n| "gest#{n}@gest.com" } factory :gestionnaire do email { generate(:gestionnaire_email) } password 'password' diff --git a/spec/factories/user.rb b/spec/factories/user.rb index 184da4b0a..c2d09396b 100644 --- a/spec/factories/user.rb +++ b/spec/factories/user.rb @@ -1,5 +1,5 @@ FactoryGirl.define do - sequence(:user_email) { |n| "plop#{n}@plop.com" } + sequence(:user_email) { |n| "user#{n}@user.com" } factory :user do email { generate(:user_email) } password 'password' diff --git a/spec/views/admin/gestionnaires/index.html.haml_spec.rb b/spec/views/admin/gestionnaires/index.html.haml_spec.rb index 0ec5c815b..7f8820abd 100644 --- a/spec/views/admin/gestionnaires/index.html.haml_spec.rb +++ b/spec/views/admin/gestionnaires/index.html.haml_spec.rb @@ -29,6 +29,6 @@ describe 'admin/gestionnaires/index.html.haml', type: :view do array: true)) render end - it { expect(rendered).to match(/gest\d+@plop.com/) } + it { expect(rendered).to match(/gest\d+@gest.com/) } end end