summaryrefslogtreecommitdiff
path: root/spec/tasks
diff options
context:
space:
mode:
authorGabriel Mazetto <brodock@gmail.com>2019-03-13 15:54:30 +0100
committerGabriel Mazetto <brodock@gmail.com>2019-03-17 00:27:38 +0100
commit523712d116a560f314cf144edbde076d7ab6fdc4 (patch)
tree393881835a092d127226e4f958929f218b5717b4 /spec/tasks
parent7d985db1404acf866e7c689fc88eb935970c90c9 (diff)
downloadgitlab-ce-523712d116a560f314cf144edbde076d7ab6fdc4.tar.gz
Fix storage migration check for non-empty queues
The previous code works fine when running specs, but the API does not exist outside that environment.
Diffstat (limited to 'spec/tasks')
-rw-r--r--spec/tasks/gitlab/storage_rake_spec.rb8
1 files changed, 4 insertions, 4 deletions
diff --git a/spec/tasks/gitlab/storage_rake_spec.rb b/spec/tasks/gitlab/storage_rake_spec.rb
index 736809eee5b..4b04d9cec39 100644
--- a/spec/tasks/gitlab/storage_rake_spec.rb
+++ b/spec/tasks/gitlab/storage_rake_spec.rb
@@ -89,9 +89,9 @@ describe 'rake gitlab:storage:*', :sidekiq do
describe 'gitlab:storage:migrate_to_hashed' do
let(:task) { 'gitlab:storage:migrate_to_hashed' }
- context 'with rollback already scheduled' do
+ context 'with rollback already scheduled', :redis do
it 'does nothing' do
- Sidekiq::Testing.fake! do
+ Sidekiq::Testing.disable! do
::HashedStorage::RollbackerWorker.perform_async(1, 5)
expect(Project).not_to receive(:with_unmigrated_storage)
@@ -146,9 +146,9 @@ describe 'rake gitlab:storage:*', :sidekiq do
it_behaves_like 'make sure database is writable'
- context 'with migration already scheduled' do
+ context 'with migration already scheduled', :redis do
it 'does nothing' do
- Sidekiq::Testing.fake! do
+ Sidekiq::Testing.disable! do
::HashedStorage::MigratorWorker.perform_async(1, 5)
expect(Project).not_to receive(:with_unmigrated_storage)