diff options
author | Robert Schilling <rschilling@student.tugraz.at> | 2014-09-30 07:53:46 +0200 |
---|---|---|
committer | Robert Schilling <rschilling@student.tugraz.at> | 2014-09-30 07:53:46 +0200 |
commit | 57c0d9ec46c9ab2a229d0f212547611c6b3446ce (patch) | |
tree | 5af059060e146d4117883a84edf0bef451f5e0a6 /spec | |
parent | 5b5912f917cfbea8c4adfe56804846ca613803c1 (diff) | |
parent | 97e2f8a0d991f189c7cb60aec3f2e1f17e928451 (diff) | |
download | gitlab-ce-57c0d9ec46c9ab2a229d0f212547611c6b3446ce.tar.gz |
Merge pull request #7870 from mr-vinn/fix-notify-spec
Update expected value in notify_spec
Diffstat (limited to 'spec')
-rw-r--r-- | spec/mailers/notify_spec.rb | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/spec/mailers/notify_spec.rb b/spec/mailers/notify_spec.rb index 799dce442cc..e06e8826e5c 100644 --- a/spec/mailers/notify_spec.rb +++ b/spec/mailers/notify_spec.rb @@ -44,7 +44,9 @@ describe Notify do let(:example_site_path) { root_path } let(:new_user) { create(:user, email: 'newguy@example.com', created_by_id: 1) } - subject { Notify.new_user_email(new_user.id, new_user.password, 'kETLwRaayvigPq_x3SNM') } + token = 'kETLwRaayvigPq_x3SNM' + + subject { Notify.new_user_email(new_user.id, new_user.password, token) } it_behaves_like 'an email sent from GitLab' @@ -65,7 +67,10 @@ describe Notify do end it 'includes a link for user to set password' do - should have_body_text 'http://localhost/users/password/edit?reset_password_token=kETLwRaayvigPq_x3SNM' + params = "reset_password_token=#{token}" + should have_body_text( + %r{http://localhost(:\d+)?/users/password/edit\?#{params}} + ) end it 'includes a link to the site' do |