about summary refs log tree commit diff
path: root/spec/controllers/admin/report_notes_controller_spec.rb
diff options
context:
space:
mode:
authorThibaut Girka <thib@sitedethib.com>2018-10-05 15:23:57 +0200
committerThibaut Girka <thib@sitedethib.com>2018-10-05 15:23:57 +0200
commit00fcdebed758f031b486ec239fd425fc54a180b3 (patch)
tree1211e136ba3e886ee8daaa5200babffc42375dd1 /spec/controllers/admin/report_notes_controller_spec.rb
parenta9e8f98a9d32c57956d41009bd09a1f33310676e (diff)
parent028ad4124cf1fdb28f5cf11bd7080e7a63f2f99e (diff)
Merge branch 'master' into glitch-soc/merge-upstream
Conflicts:
	db/migrate/20170716191202_add_hide_notifications_to_mute.rb
	spec/controllers/application_controller_spec.rb

Took our version, upstream changes were only minor style linting.
Diffstat (limited to 'spec/controllers/admin/report_notes_controller_spec.rb')
-rw-r--r--spec/controllers/admin/report_notes_controller_spec.rb11
1 files changed, 5 insertions, 6 deletions
diff --git a/spec/controllers/admin/report_notes_controller_spec.rb b/spec/controllers/admin/report_notes_controller_spec.rb
index 2c32303fb..ec5872c7d 100644
--- a/spec/controllers/admin/report_notes_controller_spec.rb
+++ b/spec/controllers/admin/report_notes_controller_spec.rb
@@ -15,7 +15,6 @@ describe Admin::ReportNotesController do
     let(:report) { Fabricate(:report, action_taken: action_taken, action_taken_by_account_id: account_id) }
 
     context 'when parameter is valid' do
-
       context 'when report is unsolved' do
         let(:action_taken) { false }
         let(:account_id) { nil }
@@ -24,7 +23,7 @@ describe Admin::ReportNotesController do
           let(:params) { { report_note: { content: 'test content', report_id: report.id }, create_and_resolve: nil } }
 
           it 'creates a report note and resolves report' do
-            expect{ subject }.to change{ ReportNote.count }.by(1)
+            expect { subject }.to change { ReportNote.count }.by(1)
             expect(report.reload).to be_action_taken
             expect(subject).to redirect_to admin_reports_path
           end
@@ -34,7 +33,7 @@ describe Admin::ReportNotesController do
           let(:params) { { report_note: { content: 'test content', report_id: report.id } } }
 
           it 'creates a report note and does not resolve report' do
-            expect{ subject }.to change{ ReportNote.count }.by(1)
+            expect { subject }.to change { ReportNote.count }.by(1)
             expect(report.reload).not_to be_action_taken
             expect(subject).to redirect_to admin_report_path(report)
           end
@@ -49,7 +48,7 @@ describe Admin::ReportNotesController do
           let(:params) { { report_note: { content: 'test content', report_id: report.id }, create_and_unresolve: nil } }
 
           it 'creates a report note and unresolves report' do
-            expect{ subject }.to change{ ReportNote.count }.by(1)
+            expect { subject }.to change { ReportNote.count }.by(1)
             expect(report.reload).not_to be_action_taken
             expect(subject).to redirect_to admin_report_path(report)
           end
@@ -59,7 +58,7 @@ describe Admin::ReportNotesController do
           let(:params) { { report_note: { content: 'test content', report_id: report.id } } }
 
           it 'creates a report note and does not unresolve report' do
-            expect{ subject }.to change{ ReportNote.count }.by(1)
+            expect { subject }.to change { ReportNote.count }.by(1)
             expect(report.reload).to be_action_taken
             expect(subject).to redirect_to admin_report_path(report)
           end
@@ -84,7 +83,7 @@ describe Admin::ReportNotesController do
     let!(:report_note) { Fabricate(:report_note) }
 
     it 'deletes note' do
-      expect{ subject }.to change{ ReportNote.count }.by(-1)
+      expect { subject }.to change { ReportNote.count }.by(-1)
       expect(subject).to redirect_to admin_report_path(report_note.report)
     end
   end