summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDouwe Maan <douwe@gitlab.com>2015-10-18 13:08:08 +0200
committerDouwe Maan <douwe@gitlab.com>2015-10-18 13:08:08 +0200
commit2e2a2a366fa5a7b1179bf34bf22128138e52e4c7 (patch)
tree9f1da99482b361d514217021add2d0393f05aad6
parent024b6fa11a3d0d4aed017997148524e0df1eb177 (diff)
downloadgitlab-ce-jrochkind/gitlab-ce-fix_2839_send_abuse_report_notify.tar.gz
-rw-r--r--spec/controllers/abuse_reports_controller_spec.rb13
1 files changed, 6 insertions, 7 deletions
diff --git a/spec/controllers/abuse_reports_controller_spec.rb b/spec/controllers/abuse_reports_controller_spec.rb
index 10a2cc3c3a4..0faab8d7ff0 100644
--- a/spec/controllers/abuse_reports_controller_spec.rb
+++ b/spec/controllers/abuse_reports_controller_spec.rb
@@ -32,13 +32,13 @@ describe AbuseReportsController do
end
it "saves the abuse report" do
- expect {
+ expect do
post :create,
abuse_report: {
user_id: user.id,
message: message
}
- }.to change { AbuseReport.count }.by(1)
+ end.to change { AbuseReport.count }.by(1)
end
end
@@ -48,24 +48,23 @@ describe AbuseReportsController do
end
it "does not send a notification email" do
- expect {
+ expect do
post :create,
abuse_report: {
user_id: user.id,
message: message
}
-
- }.not_to change { ActionMailer::Base.deliveries.count }
+ end.not_to change { ActionMailer::Base.deliveries.count }
end
it "saves the abuse report" do
- expect {
+ expect do
post :create,
abuse_report: {
user_id: user.id,
message: message
}
- }.to change { AbuseReport.count }.by(1)
+ end.to change { AbuseReport.count }.by(1)
end
end
end