diff options
author | Gabriel Mazetto <brodock@gmail.com> | 2019-01-23 05:31:57 +0300 |
---|---|---|
committer | Gabriel Mazetto <brodock@gmail.com> | 2019-03-01 17:49:20 +0300 |
commit | d63380fa93dff921c69f7aaa31ff004864e4db13 (patch) | |
tree | 5473628a284c200222fddc9c1e7775e691c763bc /spec/lib/gitlab/hashed_storage | |
parent | 1592b5830f7b2847dff02ef2c66b745cdc60565a (diff) |
Refactor ProjectMigrate and ProjectRollback workers
Moved to HashedStorage namespace, and added them to the
`:hashed_storage` queue namespace
Diffstat (limited to 'spec/lib/gitlab/hashed_storage')
-rw-r--r-- | spec/lib/gitlab/hashed_storage/migrator_spec.rb | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/spec/lib/gitlab/hashed_storage/migrator_spec.rb b/spec/lib/gitlab/hashed_storage/migrator_spec.rb index 7c2582bb27a..000913f32bb 100644 --- a/spec/lib/gitlab/hashed_storage/migrator_spec.rb +++ b/spec/lib/gitlab/hashed_storage/migrator_spec.rb @@ -13,9 +13,9 @@ describe Gitlab::HashedStorage::Migrator do let(:projects) { create_list(:project, 2, :legacy_storage) } let(:ids) { projects.map(&:id) } - it 'enqueue jobs to ProjectMigrateHashedStorageWorker' do + it 'enqueue jobs to HashedStorage::ProjectMigrateWorker' do Sidekiq::Testing.fake! do - expect { subject.bulk_migrate(start: ids.min, finish: ids.max) }.to change(ProjectMigrateHashedStorageWorker.jobs, :size).by(2) + expect { subject.bulk_migrate(start: ids.min, finish: ids.max) }.to change(HashedStorage::ProjectMigrateWorker.jobs, :size).by(2) end end @@ -48,7 +48,7 @@ describe Gitlab::HashedStorage::Migrator do it 'enqueues project migration job' do Sidekiq::Testing.fake! do - expect { subject.migrate(project) }.to change(ProjectMigrateHashedStorageWorker.jobs, :size).by(1) + expect { subject.migrate(project) }.to change(HashedStorage::ProjectMigrateWorker.jobs, :size).by(1) end end @@ -79,7 +79,7 @@ describe Gitlab::HashedStorage::Migrator do it 'doesnt enqueue any migration job' do Sidekiq::Testing.fake! do - expect { subject.migrate(project) }.not_to change(ProjectMigrateHashedStorageWorker.jobs, :size) + expect { subject.migrate(project) }.not_to change(HashedStorage::ProjectMigrateWorker.jobs, :size) end end @@ -94,7 +94,7 @@ describe Gitlab::HashedStorage::Migrator do it 'enqueues project rollback job' do Sidekiq::Testing.fake! do - expect { subject.rollback(project) }.to change(ProjectRollbackHashedStorageWorker.jobs, :size).by(1) + expect { subject.rollback(project) }.to change(HashedStorage::ProjectRollbackWorker.jobs, :size).by(1) end end @@ -125,7 +125,7 @@ describe Gitlab::HashedStorage::Migrator do it 'doesnt enqueue any rollback job' do Sidekiq::Testing.fake! do - expect { subject.rollback(project) }.not_to change(ProjectRollbackHashedStorageWorker.jobs, :size) + expect { subject.rollback(project) }.not_to change(HashedStorage::ProjectRollbackWorker.jobs, :size) end end |