Skip to content
代码片段 群组 项目
提交 b1aec864 编辑于 作者: Justin Ho Tuan Duong's avatar Justin Ho Tuan Duong
浏览文件

Remove import_details_page feature flag

Show import details link and page by default.

Changelog: other
上级 348b8d68
No related branches found
No related tags found
无相关合并请求
<script>
import { GlAccordion, GlAccordionItem, GlBadge, GlIcon, GlLink } from '@gitlab/ui';
import { __, s__ } from '~/locale';
import glFeatureFlagMixin from '~/vue_shared/mixins/gl_feature_flags_mixin';
import { STATISTIC_ITEMS } from '~/import/constants';
import { STATUSES } from '../constants';
......@@ -58,7 +57,6 @@ export default {
GlIcon,
GlLink,
},
mixins: [glFeatureFlagMixin()],
inject: {
detailsPath: {
default: undefined,
......@@ -116,11 +114,7 @@ export default {
},
showDetails() {
return (
Boolean(this.detailsPathForProject) &&
this.glFeatures.importDetailsPage &&
this.isIncomplete
);
return Boolean(this.detailsPathForProject) && this.isIncomplete;
},
detailsPathForProject() {
......
......@@ -13,10 +13,6 @@ class Import::GithubController < Import::BaseController
before_action :provider_auth, only: [:status, :realtime_changes, :create]
before_action :expire_etag_cache, only: [:status, :create]
before_action only: [:status] do
push_frontend_feature_flag(:import_details_page)
end
rescue_from Octokit::Unauthorized, with: :provider_unauthorized
rescue_from Octokit::TooManyRequests, with: :provider_rate_limit
rescue_from Gitlab::GithubImport::RateLimitError, with: :rate_limit_threshold_exceeded
......@@ -73,9 +69,7 @@ def status
end
end
def details
render_404 unless Feature.enabled?(:import_details_page)
end
def details; end
def create
result = Import::GithubService.new(client, current_user, import_params).execute(access_params, provider_name)
......
---
name: import_details_page
introduced_by_url: https://gitlab.com/gitlab-org/gitlab/-/merge_requests/116090
rollout_issue_url: https://gitlab.com/gitlab-org/gitlab/-/issues/397650
milestone: '15.11'
type: development
group: group::import
default_enabled: true
......@@ -168,18 +168,14 @@ describe('Import entities status component', () => {
};
describe.each`
detailsPath | importDetailsPage | partialImport | expectLink
${undefined} | ${false} | ${false} | ${false}
${undefined} | ${false} | ${true} | ${false}
${undefined} | ${true} | ${false} | ${false}
${undefined} | ${true} | ${true} | ${false}
${mockDetailsPath} | ${false} | ${false} | ${false}
${mockDetailsPath} | ${false} | ${true} | ${false}
${mockDetailsPath} | ${true} | ${false} | ${false}
${mockDetailsPath} | ${true} | ${true} | ${true}
detailsPath | partialImport | expectLink
${undefined} | ${false} | ${false}
${undefined} | ${true} | ${false}
${mockDetailsPath} | ${false} | ${false}
${mockDetailsPath} | ${true} | ${true}
`(
'when detailsPath is $detailsPath, feature flag importDetailsPage is $importDetailsPage, partial import is $partialImport',
({ detailsPath, importDetailsPage, partialImport, expectLink }) => {
'when detailsPath is $detailsPath, partial import is $partialImport',
({ detailsPath, partialImport, expectLink }) => {
beforeEach(() => {
createComponent(
{
......@@ -190,7 +186,6 @@ describe('Import entities status component', () => {
{
provide: {
detailsPath,
glFeatures: { importDetailsPage },
},
},
);
......
......@@ -12,31 +12,13 @@
stub_application_setting(import_sources: ['github'])
login_as(user)
end
context 'with feature enabled' do
before do
stub_feature_flags(import_details_page: true)
request
end
it 'responds with a 200 and shows the template', :aggregate_failures do
expect(response).to have_gitlab_http_status(:ok)
expect(response).to render_template(:details)
end
request
end
context 'with feature disabled' do
before do
stub_feature_flags(import_details_page: false)
request
end
it 'responds with a 404' do
expect(response).to have_gitlab_http_status(:not_found)
end
it 'responds with a 200 and shows the template', :aggregate_failures do
expect(response).to have_gitlab_http_status(:ok)
expect(response).to render_template(:details)
end
end
end
0% 加载中 .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册