summaryrefslogtreecommitdiff
path: root/spec/migrations/active_record
diff options
context:
space:
mode:
authorblackst0ne <blackst0ne.ru@gmail.com>2018-07-23 15:34:54 +1100
committerblackst0ne <blackst0ne.ru@gmail.com>2018-07-23 15:34:54 +1100
commitddd2a25679f1d875332f603f115e25577b05a5a2 (patch)
tree2fb343f92c44755dae2294d9a9d0013045c5501a /spec/migrations/active_record
parentdc7b4b7bb97ead6fca1eefad5f56c8db5db00f93 (diff)
downloadgitlab-ce-ddd2a25679f1d875332f603f115e25577b05a5a2.tar.gz
Replace 'Sidekiq::Testing.inline!' with 'perform_enqueued_jobs'
`perform_enqueued_jobs` is a Sidekiq method. Using this method violates the Dependency inversion principle[0]. This commit replaces `perform_enqueued_jobs` with ActiveJob's abstract method `perform_enqueued_jobs` in specs. [0]: https://en.wikipedia.org/wiki/Dependency_inversion_principle
Diffstat (limited to 'spec/migrations/active_record')
-rw-r--r--spec/migrations/active_record/schedule_set_confidential_note_events_on_services_spec.rb2
1 files changed, 1 insertions, 1 deletions
diff --git a/spec/migrations/active_record/schedule_set_confidential_note_events_on_services_spec.rb b/spec/migrations/active_record/schedule_set_confidential_note_events_on_services_spec.rb
index 4395e2f8264..5c6f213e15b 100644
--- a/spec/migrations/active_record/schedule_set_confidential_note_events_on_services_spec.rb
+++ b/spec/migrations/active_record/schedule_set_confidential_note_events_on_services_spec.rb
@@ -31,7 +31,7 @@ describe ScheduleSetConfidentialNoteEventsOnServices, :migration, :sidekiq do
end
it 'correctly processes services' do
- Sidekiq::Testing.inline! do
+ perform_enqueued_jobs do
expect(services_table.where(confidential_note_events: nil).count).to eq 4
expect(services_table.where(confidential_note_events: true).count).to eq 1