Commit eb770e7f authored by Fernando's avatar Fernando

Remove old feature flag for policy list

parent 06c42094
...@@ -57,9 +57,6 @@ export default { ...@@ -57,9 +57,6 @@ export default {
hasEmptyState() { hasEmptyState() {
return Boolean(!this.isJobSetUp || this.isJobFailed); return Boolean(!this.isJobSetUp || this.isJobFailed);
}, },
hasLicensePolicyList() {
return Boolean(this.glFeatures.licensePolicyList);
},
licenseCount() { licenseCount() {
return this.pageInfo.total; return this.pageInfo.total;
}, },
...@@ -134,8 +131,7 @@ export default { ...@@ -134,8 +131,7 @@ export default {
<template v-else>{{ s__('Licenses|Specified policies in this project') }}</template> <template v-else>{{ s__('Licenses|Specified policies in this project') }}</template>
</header> </header>
<!-- TODO: Remove feature flag --> <template>
<template v-if="hasLicensePolicyList">
<gl-tabs v-model="tabIndex" content-class="pt-0"> <gl-tabs v-model="tabIndex" content-class="pt-0">
<gl-tab data-testid="licensesTab"> <gl-tab data-testid="licensesTab">
<template #title> <template #title>
...@@ -157,8 +153,5 @@ export default { ...@@ -157,8 +153,5 @@ export default {
</gl-tabs> </gl-tabs>
</template> </template>
<template v-else>
<detected-licenses-table class="mt-3" />
</template>
</div> </div>
</template> </template>
...@@ -164,7 +164,7 @@ describe('Project Licenses', () => { ...@@ -164,7 +164,7 @@ describe('Project Licenses', () => {
}); });
}); });
describe('when licensePolicyList feature flag is enabled', () => { describe('when page is shown', () => {
beforeEach(() => { beforeEach(() => {
createComponent({ createComponent({
state: { state: {
...@@ -175,11 +175,6 @@ describe('Project Licenses', () => { ...@@ -175,11 +175,6 @@ describe('Project Licenses', () => {
status: REPORT_STATUS.ok, status: REPORT_STATUS.ok,
}, },
}, },
options: {
provide: {
glFeatures: { licensePolicyList: true },
},
},
}); });
}); });
...@@ -231,9 +226,6 @@ describe('Project Licenses', () => { ...@@ -231,9 +226,6 @@ describe('Project Licenses', () => {
pageInfo: 1, pageInfo: 1,
}, },
options: { options: {
provide: {
glFeatures: { licensePolicyList: true },
},
mount: true, mount: true,
}, },
}); });
...@@ -274,9 +266,6 @@ describe('Project Licenses', () => { ...@@ -274,9 +266,6 @@ describe('Project Licenses', () => {
pageInfo, pageInfo,
}, },
options: { options: {
provide: {
glFeatures: { licensePolicyList: true },
},
mount: true, mount: true,
}, },
}); });
...@@ -335,42 +324,4 @@ describe('Project Licenses', () => { ...@@ -335,42 +324,4 @@ describe('Project Licenses', () => {
}); });
}); });
describe('when licensePolicyList feature flag is disabled', () => {
beforeEach(() => {
createComponent({
state: {
initialized: true,
reportInfo: {
jobPath: '/',
generatedAt: '',
status: REPORT_STATUS.ok,
},
},
options: {
provide: {
glFeatures: { licensePolicyList: false },
},
},
});
});
it('only renders the "Detected in project" table', () => {
expect(wrapper.find(DetectedLicensesTable).exists()).toBe(true);
expect(wrapper.find(LicenseManagement).exists()).toBe(false);
});
it('renders no "Policies" table', () => {
expect(wrapper.find(GlTabs).exists()).toBe(false);
expect(wrapper.find(GlTab).exists()).toBe(false);
});
it('renders the pipeline info', () => {
expect(wrapper.find(PipelineInfo).exists()).toBe(true);
});
it('renders no tabs', () => {
expect(wrapper.find(GlTabs).exists()).toBe(false);
expect(wrapper.find(GlTab).exists()).toBe(false);
});
});
}); });
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