summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2018-11-16 23:49:33 +0000
committerStan Hu <stanhu@gmail.com>2018-11-16 23:49:33 +0000
commit29d8179ba07be3ed111f939285eb4064d84cb7df (patch)
treec847c6faf1b6d6601ef0573aca34622ad8b7f8a6 /spec
parent85bc7844d626675e963a6ed7b306390eeb82ad83 (diff)
parentf208f4c236b4ea464842407a23d428d84e07038a (diff)
downloadgitlab-ce-29d8179ba07be3ed111f939285eb4064d84cb7df.tar.gz
Merge branch '53700-hashed-storagemigration' into 'master'
Hashed Storage: allow migration to be retried in partially migrated projects Closes #53700 See merge request gitlab-org/gitlab-ce!23087
Diffstat (limited to 'spec')
-rw-r--r--spec/models/project_spec.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/spec/models/project_spec.rb b/spec/models/project_spec.rb
index bdff68cee8b..51278836604 100644
--- a/spec/models/project_spec.rb
+++ b/spec/models/project_spec.rb
@@ -3087,6 +3087,14 @@ describe Project do
it 'does not flag as read-only' do
expect { project.migrate_to_hashed_storage! }.not_to change { project.repository_read_only }
end
+
+ context 'when partially migrated' do
+ it 'returns true' do
+ project = create(:project, storage_version: 1, skip_disk_validation: true)
+
+ expect(project.migrate_to_hashed_storage!).to be_truthy
+ end
+ end
end
end