summaryrefslogtreecommitdiff
path: root/spec/mailers
diff options
context:
space:
mode:
authorRiyad Preukschas <riyad@informatik.uni-bremen.de>2012-08-06 05:08:22 +0200
committerRiyad Preukschas <riyad@informatik.uni-bremen.de>2012-08-06 05:08:22 +0200
commit5443021a0e16887d14189f4203aea7f9282a1853 (patch)
tree50660a3958d92dd5f0b91675ecf5441b52266b4c /spec/mailers
parent9a0b763eece1305437a7410cf9e6debca9a8670b (diff)
downloadgitlab-ce-5443021a0e16887d14189f4203aea7f9282a1853.tar.gz
Update notifications mails and notify specs for GFM
Diffstat (limited to 'spec/mailers')
-rw-r--r--spec/mailers/notify_spec.rb14
1 files changed, 8 insertions, 6 deletions
diff --git a/spec/mailers/notify_spec.rb b/spec/mailers/notify_spec.rb
index 4df771b97fe..010f063a98d 100644
--- a/spec/mailers/notify_spec.rb
+++ b/spec/mailers/notify_spec.rb
@@ -60,7 +60,7 @@ describe Notify do
it_behaves_like 'an assignee email'
it 'has the correct subject' do
- should have_subject /New Issue was created/
+ should have_subject /new issue ##{issue.id}/
end
it 'contains a link to the new issue' do
@@ -102,7 +102,7 @@ describe Notify do
it_behaves_like 'an assignee email'
it 'has the correct subject' do
- should have_subject /new merge request/
+ should have_subject /new merge request !#{merge_request.id}/
end
it 'contains a link to the new merge request' do
@@ -126,7 +126,7 @@ describe Notify do
it_behaves_like 'a multiple recipients email'
it 'has the correct subject' do
- should have_subject /merge request changed/
+ should have_subject /changed merge request !#{merge_request.id}/
end
it 'contains the name of the previous assignee' do
@@ -188,6 +188,8 @@ describe Notify do
mock(:commit).tap do |commit|
commit.stub(:id).and_return('fauxsha1')
commit.stub(:project).and_return(project)
+ commit.stub(:short_id).and_return('fauxsha1')
+ commit.stub(:safe_message).and_return('some message')
end
end
before(:each) { note.stub(:target).and_return(commit) }
@@ -197,7 +199,7 @@ describe Notify do
it_behaves_like 'a note email'
it 'has the correct subject' do
- should have_subject /note for commit/
+ should have_subject /note for commit #{commit.short_id}/
end
it 'contains a link to the commit' do
@@ -215,7 +217,7 @@ describe Notify do
it_behaves_like 'a note email'
it 'has the correct subject' do
- should have_subject /note for merge request/
+ should have_subject /note for merge request !#{merge_request.id}/
end
it 'contains a link to the merge request note' do
@@ -233,7 +235,7 @@ describe Notify do
it_behaves_like 'a note email'
it 'has the correct subject' do
- should have_subject /note for issue #{issue.id}/
+ should have_subject /note for issue ##{issue.id}/
end
it 'contains a link to the issue note' do