Commit 09908958 authored by Gabriel Mazetto's avatar Gabriel Mazetto
Browse files

Rename feature flag to skip_hashed_storage_upgrade to be less confusing

parent a9ed2f34f010
......@@ -2074,7 +2074,7 @@ def auto_cancel_pending_pipelines?
def rename_or_migrate_repository!
if Gitlab::CurrentSettings.hashed_storage_enabled? &&
storage_upgradable? &&
Feature.disabled?(:disable_hashed_storage_upgrade) # kill switch in case we need to disable upgrade behavior
Feature.disabled?(:skip_hashed_storage_upgrade) # kill switch in case we need to disable upgrade behavior
::Projects::HashedStorageMigrationService.new(self, full_path_was).execute
else
storage.rename_repo
......
......@@ -2989,7 +2989,7 @@ def enable_lfs
# call. This makes testing a bit easier.
allow(project).to receive(:gitlab_shell).and_return(gitlab_shell)
allow(project).to receive(:previous_changes).and_return('path' => ['foo'])
stub_feature_flags(disable_hashed_storage_upgrade: false)
stub_feature_flags(skip_hashed_storage_upgrade: false)
end
it 'renames a repository' do
......@@ -3161,7 +3161,7 @@ def enable_lfs
# call. This makes testing a bit easier.
allow(project).to receive(:gitlab_shell).and_return(gitlab_shell)
allow(project).to receive(:previous_changes).and_return('path' => ['foo'])
stub_feature_flags(disable_hashed_storage_upgrade: false)
stub_feature_flags(skip_hashed_storage_upgrade: false)
end
context 'migration to hashed storage' do
......
......@@ -262,7 +262,7 @@
context 'when hashed storage is enabled' do
before do
stub_application_setting(hashed_storage_enabled: true)
stub_feature_flags(disable_hashed_storage_upgrade: false)
stub_feature_flags(skip_hashed_storage_upgrade: false)
end
it 'migrates project to a hashed storage instead of renaming the repo to another legacy name' do
......@@ -274,9 +274,9 @@
expect(project.reload.hashed_storage?(:repository)).to be_truthy
end
context 'when disable_hashed_storage_upgrade feature flag is enabled' do
context 'when skip_hashed_storage_upgrade feature flag is enabled' do
before do
stub_feature_flags(disable_hashed_storage_upgrade: true)
stub_feature_flags(skip_hashed_storage_upgrade: true)
end
it 'renames the project without upgrading it' do
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment