diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-20 14:10:13 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2022-06-20 14:10:13 +0300 |
commit | 0ea3fcec397b69815975647f5e2aa5fe944a8486 (patch) | |
tree | 7979381b89d26011bcf9bdc989a40fcc2f1ed4ff /spec/models/project_statistics_spec.rb | |
parent | 72123183a20411a36d607d70b12d57c484394c8e (diff) |
Add latest changes from gitlab-org/gitlab@15-1-stable-eev15.1.0-rc42
Diffstat (limited to 'spec/models/project_statistics_spec.rb')
-rw-r--r-- | spec/models/project_statistics_spec.rb | 26 |
1 files changed, 12 insertions, 14 deletions
diff --git a/spec/models/project_statistics_spec.rb b/spec/models/project_statistics_spec.rb index 2c29d4c42f4..53175a2f840 100644 --- a/spec/models/project_statistics_spec.rb +++ b/spec/models/project_statistics_spec.rb @@ -54,6 +54,18 @@ RSpec.describe ProjectStatistics do end end + describe 'namespace relatable columns' do + it 'treats the correct columns as namespace relatable' do + expect(described_class::NAMESPACE_RELATABLE_COLUMNS).to match_array %i[ + repository_size + wiki_size + lfs_objects_size + uploads_size + container_registry_size + ] + end + end + describe '#total_repository_size' do it "sums repository and LFS object size" do statistics.repository_size = 2 @@ -346,20 +358,6 @@ RSpec.describe ProjectStatistics do expect(statistics.container_registry_size).to eq(0) end - - context 'with container_registry_project_statistics FF disabled' do - before do - stub_feature_flags(container_registry_project_statistics: false) - end - - it 'does not update the container_registry_size' do - expect(project).not_to receive(:container_repositories_size) - - update_container_registry_size - - expect(statistics.container_registry_size).to eq(0) - end - end end describe '#update_storage_size' do |