Commit a453e656 authored by Axel García's avatar Axel García

Remove references to createEpicForm feature flag

This feature flag was used to ship the feature
incrementally, so there is no use case for it
after deployment.

Related issue:
https://gitlab.com/gitlab-org/gitlab/-/issues/230742
parent f3caeb39
......@@ -7,7 +7,6 @@ import { __ } from '~/locale';
import tooltip from '~/vue_shared/directives/tooltip';
import UserAvatarLink from '~/vue_shared/components/user_avatar/user_avatar_link.vue';
import TimeagoTooltip from '~/vue_shared/components/time_ago_tooltip.vue';
import glFeatureFlagsMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import epicUtils from '../utils/epic_utils';
import { statusType } from '../constants';
......@@ -24,7 +23,6 @@ export default {
GitlabTeamMemberBadge: () =>
import('ee_component/vue_shared/components/user_avatar/badges/gitlab_team_member_badge.vue'),
},
mixins: [glFeatureFlagsMixin()],
computed: {
...mapState([
'sidebarCollapsed',
......@@ -50,9 +48,6 @@ export default {
actionButtonText() {
return this.isEpicOpen ? __('Close epic') : __('Reopen epic');
},
userCanCreate() {
return this.canCreate && this.glFeatures.createEpicForm;
},
},
mounted() {
/**
......@@ -141,7 +136,7 @@ export default {
{{ actionButtonText }}
</gl-button>
<gl-button
v-if="userCanCreate"
v-if="canCreate"
:href="newEpicWebUrl"
category="secondary"
variant="success"
......
......@@ -19,7 +19,6 @@ class Groups::EpicsController < Groups::ApplicationController
before_action do
push_frontend_feature_flag(:vue_issuable_epic_sidebar, @group)
push_frontend_feature_flag(:confidential_epics, @group, default_enabled: true)
push_frontend_feature_flag(:create_epic_form, @group, default_enabled: true)
end
def new; end
......
- create_group_epic = can?(current_user, :create_epic, @group)
- return unless create_group_epic && Feature.enabled?(:create_epic_form)
- return unless can?(current_user, :create_epic, @group)
%li= link_to _('New epic'), new_group_epic_path(@group)
......@@ -12,7 +12,6 @@ import { mockEpicMeta, mockEpicData } from '../mock_data';
describe('EpicHeaderComponent', () => {
let wrapper;
let store;
let features = {};
beforeEach(() => {
store = createStore();
......@@ -21,9 +20,6 @@ describe('EpicHeaderComponent', () => {
wrapper = shallowMount(EpicHeader, {
store,
provide: {
glFeatures: features,
},
});
});
......@@ -169,29 +165,19 @@ describe('EpicHeaderComponent', () => {
});
});
it('does not render new epic button without `createEpicForm` feature flag', () => {
expect(findNewEpicButton().exists()).toBeFalsy();
});
it('does not render new epic button if user cannot create it', () => {
store.state.canCreate = false;
describe('with `createEpicForm` feature flag', () => {
beforeAll(() => {
features = { createEpicForm: true };
});
it('does not render new epic button if user cannot create it', () => {
store.state.canCreate = false;
return wrapper.vm.$nextTick().then(() => {
expect(findNewEpicButton().exists()).toBe(false);
});
return wrapper.vm.$nextTick().then(() => {
expect(findNewEpicButton().exists()).toBe(false);
});
});
it('renders new epic button if user can create it', () => {
store.state.canCreate = true;
it('renders new epic button if user can create it', () => {
store.state.canCreate = true;
return wrapper.vm.$nextTick().then(() => {
expect(findNewEpicButton().exists()).toBe(true);
});
return wrapper.vm.$nextTick().then(() => {
expect(findNewEpicButton().exists()).toBe(true);
});
});
});
......
......@@ -41,21 +41,6 @@ RSpec.describe 'layouts/header/_new_dropdown' do
href: new_group_epic_path(group)
)
end
context 'with the create_epic_form feature flag disabled' do
before do
stub_feature_flags(create_epic_form: false)
end
it 'does not have "New epic" link' do
render
expect(rendered).not_to have_link(
'New epic',
href: new_group_epic_path(group)
)
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