diff options
author | Viktor Vorona <viktor.vorona@sonarsource.com> | 2024-10-09 09:53:38 +0200 |
---|---|---|
committer | sonartech <sonartech@sonarsource.com> | 2024-10-16 20:02:59 +0000 |
commit | c8d599a0ee672ee5e7c5db2d88cb1b6482d65db7 (patch) | |
tree | 32887e96c9223c1147c783965bb71f7ae66fb981 /server/sonar-web/src/main/js/apps | |
parent | fc85e01586e220eab0b385a74c71843d861babca (diff) | |
download | sonarqube-c8d599a0ee672ee5e7c5db2d88cb1b6482d65db7.tar.gz sonarqube-c8d599a0ee672ee5e7c5db2d88cb1b6482d65db7.zip |
SONAR-23188 MQR Mode setting
Diffstat (limited to 'server/sonar-web/src/main/js/apps')
5 files changed, 9 insertions, 9 deletions
diff --git a/server/sonar-web/src/main/js/apps/component-measures/__tests__/ComponentMeasures-it.tsx b/server/sonar-web/src/main/js/apps/component-measures/__tests__/ComponentMeasures-it.tsx index 01043b60288..c3eecceb27b 100644 --- a/server/sonar-web/src/main/js/apps/component-measures/__tests__/ComponentMeasures-it.tsx +++ b/server/sonar-web/src/main/js/apps/component-measures/__tests__/ComponentMeasures-it.tsx @@ -106,7 +106,7 @@ describe('rendering', () => { }); it('should correctly render the default overview and navigation in legacy mode', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); const { ui, user } = getPageObject(); renderMeasuresApp(); @@ -212,7 +212,7 @@ describe('rendering', () => { }); it('should show old measures and no flag message if no rating measures and legacy mode', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); measuresHandler.deleteComponentMeasure( 'foo', MetricKey.software_quality_maintainability_rating, diff --git a/server/sonar-web/src/main/js/apps/overview/branches/__tests__/BranchOverview-it.tsx b/server/sonar-web/src/main/js/apps/overview/branches/__tests__/BranchOverview-it.tsx index 4979f7546be..e4fc40a4682 100644 --- a/server/sonar-web/src/main/js/apps/overview/branches/__tests__/BranchOverview-it.tsx +++ b/server/sonar-web/src/main/js/apps/overview/branches/__tests__/BranchOverview-it.tsx @@ -487,7 +487,7 @@ describe('project overview', () => { }); it('should display old measures if in legacy mode', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); const { user, ui } = getPageObjects(); renderBranchOverview(); @@ -526,7 +526,7 @@ describe('project overview', () => { MetricKey.software_quality_maintainability_rating, ); measuresHandler.deleteComponentMeasure('foo', MetricKey.software_quality_reliability_rating); - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); const { user, ui } = getPageObjects(); renderBranchOverview(); diff --git a/server/sonar-web/src/main/js/apps/projectActivity/components/__tests__/ProjectActivityApp-it.tsx b/server/sonar-web/src/main/js/apps/projectActivity/components/__tests__/ProjectActivityApp-it.tsx index e8132d76bef..ce6c00ae23e 100644 --- a/server/sonar-web/src/main/js/apps/projectActivity/components/__tests__/ProjectActivityApp-it.tsx +++ b/server/sonar-web/src/main/js/apps/projectActivity/components/__tests__/ProjectActivityApp-it.tsx @@ -687,7 +687,7 @@ describe('ratings', () => { }); it('should not show gaps message and metric change button in legacy mode', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); timeMachineHandler.setMeasureHistory([ mockMeasureHistory({ metric: MetricKey.reliability_rating, diff --git a/server/sonar-web/src/main/js/apps/projects/components/__tests__/PageSidebar-test.tsx b/server/sonar-web/src/main/js/apps/projects/components/__tests__/PageSidebar-test.tsx index 927df18e7aa..c1d41c9b149 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/__tests__/PageSidebar-test.tsx +++ b/server/sonar-web/src/main/js/apps/projects/components/__tests__/PageSidebar-test.tsx @@ -85,7 +85,7 @@ it('should allow to clear all filters', async () => { }); it('should show legacy filters', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); renderPageSidebar(); expect(await screen.findAllByText(/projects.facets.rating_option/)).toHaveLength(20); @@ -96,7 +96,7 @@ it('should show legacy filters', async () => { }); it('should show non legacy filters', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'false'); + settingsHandler.set(SettingsKey.MQRMode, 'true'); renderPageSidebar(); expect(await screen.findAllByText(/projects.facets.rating_option/)).toHaveLength(20); diff --git a/server/sonar-web/src/main/js/apps/projects/components/project-card/__tests__/ProjectCard-test.tsx b/server/sonar-web/src/main/js/apps/projects/components/project-card/__tests__/ProjectCard-test.tsx index f2754c4aeaf..b6bd24cf673 100644 --- a/server/sonar-web/src/main/js/apps/projects/components/project-card/__tests__/ProjectCard-test.tsx +++ b/server/sonar-web/src/main/js/apps/projects/components/project-card/__tests__/ProjectCard-test.tsx @@ -310,7 +310,7 @@ describe('upgrade scenario (awaiting scan)', () => { }); it('should not display awaiting analysis badge if legacy mode is enabled', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); renderProjectCard({ ...PROJECT, measures: { @@ -329,7 +329,7 @@ describe('upgrade scenario (awaiting scan)', () => { }); it('should not display new values if legacy mode is enabled', async () => { - settingsHandler.set(SettingsKey.LegacyMode, 'true'); + settingsHandler.set(SettingsKey.MQRMode, 'false'); measuresHandler.registerComponentMeasures({ [PROJECT.key]: { ...newRatings, |