Commit 83ff17c7 authored by Nathan Friend's avatar Nathan Friend

Remove group_level_release_statistics flag

This commit removes the group_level_release_statistics feature flag.
parent b5be8cd0
...@@ -9279,8 +9279,8 @@ Contains release-related statistics about a group. ...@@ -9279,8 +9279,8 @@ Contains release-related statistics about a group.
| Name | Type | Description | | Name | Type | Description |
| ---- | ---- | ----------- | | ---- | ---- | ----------- |
| <a id="groupreleasestatsreleasescount"></a>`releasesCount` | [`Int`](#int) | Total number of releases in all descendant projects of the group. Will always return `null` if `group_level_release_statistics` feature flag is disabled. | | <a id="groupreleasestatsreleasescount"></a>`releasesCount` | [`Int`](#int) | Total number of releases in all descendant projects of the group. |
| <a id="groupreleasestatsreleasespercentage"></a>`releasesPercentage` | [`Int`](#int) | Percentage of the group's descendant projects that have at least one release. Will always return `null` if `group_level_release_statistics` feature flag is disabled. | | <a id="groupreleasestatsreleasespercentage"></a>`releasesPercentage` | [`Int`](#int) | Percentage of the group's descendant projects that have at least one release. |
### `GroupStats` ### `GroupStats`
......
...@@ -8,19 +8,17 @@ module Types ...@@ -8,19 +8,17 @@ module Types
authorize :read_group_release_stats authorize :read_group_release_stats
field :releases_count, GraphQL::INT_TYPE, null: true, field :releases_count, GraphQL::INT_TYPE, null: true,
description: 'Total number of releases in all descendant projects of the group. ' \ description: 'Total number of releases in all descendant projects of the group.'
'Will always return `null` if `group_level_release_statistics` feature flag is disabled'
def releases_count def releases_count
object.releases_count if Feature.enabled?(:group_level_release_statistics, object, default_enabled: true) object.releases_count
end end
field :releases_percentage, GraphQL::INT_TYPE, null: true, field :releases_percentage, GraphQL::INT_TYPE, null: true,
description: "Percentage of the group's descendant projects that have at least one release. " \ description: "Percentage of the group's descendant projects that have at least one release."
'Will always return `null` if `group_level_release_statistics` feature flag is disabled'
def releases_percentage def releases_percentage
object.releases_percentage if Feature.enabled?(:group_level_release_statistics, object, default_enabled: true) object.releases_percentage
end end
end end
end end
---
title: Remove group_level_release_statistics flag
merge_request: 61806
author:
type: other
---
name: group_level_release_statistics
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/47245
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/283962
milestone: '13.6'
type: development
group: group::release
default_enabled: true
...@@ -249,8 +249,6 @@ RSpec.describe 'getting group information' do ...@@ -249,8 +249,6 @@ RSpec.describe 'getting group information' do
QUERY QUERY
end end
let(:group_level_release_statistics) { true }
let(:query) do let(:query) do
graphql_query_for('group', { 'fullPath' => group.full_path }, query_fields) graphql_query_for('group', { 'fullPath' => group.full_path }, query_fields)
end end
...@@ -260,8 +258,6 @@ RSpec.describe 'getting group information' do ...@@ -260,8 +258,6 @@ RSpec.describe 'getting group information' do
end end
before do before do
stub_feature_flags(group_level_release_statistics: group_level_release_statistics)
group.add_guest(guest_user) group.add_guest(guest_user)
post_graphql(query, current_user: current_user) post_graphql(query, current_user: current_user)
...@@ -334,20 +330,6 @@ RSpec.describe 'getting group information' do ...@@ -334,20 +330,6 @@ RSpec.describe 'getting group information' do
it_behaves_like 'correct access to release statistics' it_behaves_like 'correct access to release statistics'
end end
context 'when the group_level_release_statistics feature flag is disabled' do
let_it_be(:group) { create(:group, :public) }
let(:current_user) { guest_user }
let(:group_level_release_statistics) { false }
it 'returns null for both statistics' do
expect(release_stats).to match(
releasesCount: nil,
releasesPercentage: nil
)
end
end
end end
end end
......
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