From 37c269548076c463d60807bd01b00f37eddb27aa Mon Sep 17 00:00:00 2001 From: Derek Ho Date: Tue, 14 May 2024 12:15:47 -0400 Subject: [PATCH] Revert "Remove MDS selector for tenancy tab (#1937)" (#1943) This reverts commit 9d0f262672e8398a19a3f8b6c1635e56a4007c58. Co-authored-by: Darshit Chanpura --- .../apps/configuration/panels/tenant-list/tenant-list.tsx | 8 ++++++++ .../multi-datasources/multi_datasources_enabled.spec.js | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/public/apps/configuration/panels/tenant-list/tenant-list.tsx b/public/apps/configuration/panels/tenant-list/tenant-list.tsx index 6a4f53382..0b97c6ae1 100644 --- a/public/apps/configuration/panels/tenant-list/tenant-list.tsx +++ b/public/apps/configuration/panels/tenant-list/tenant-list.tsx @@ -31,6 +31,8 @@ import { ExternalLink } from '../../utils/display-utils'; import { DocLinks } from '../../constants'; import { getDashboardsInfo } from '../../../../utils/dashboards-info-utils'; import { TenantInstructionView } from './tenant-instruction-view'; +import { LocalCluster } from '../../app-router'; +import { SecurityPluginTopNavMenu } from '../../top-nav-menu'; interface TenantListProps extends AppDependencies { tabID: string; @@ -133,6 +135,12 @@ export function TenantList(props: TenantListProps) { return ( <> + {}} + selectedDataSource={LocalCluster} + />

Dashboards multi-tenancy

diff --git a/test/cypress/e2e/multi-datasources/multi_datasources_enabled.spec.js b/test/cypress/e2e/multi-datasources/multi_datasources_enabled.spec.js index c9f3ae989..2a1a0c4f7 100644 --- a/test/cypress/e2e/multi-datasources/multi_datasources_enabled.spec.js +++ b/test/cypress/e2e/multi-datasources/multi_datasources_enabled.spec.js @@ -159,7 +159,7 @@ describe('Multi-datasources enabled', () => { cy.visit(`http://localhost:5601/app/security-dashboards-plugin${localDataSourceUrl}#/tenants`); cy.contains('h1', 'Dashboards multi-tenancy'); - cy.get('[data-test-subj="dataSourceSelectableButton"]').should('not.exist'); + cy.get('[data-test-subj="dataSourceViewButton"]').should('contain', 'Local cluster'); }); it('Checks Service Accounts Tab', () => {