From 230379f3480be1e690e5bf490b78ac24dc932bb0 Mon Sep 17 00:00:00 2001 From: Charles Sibbald Date: Mon, 25 Nov 2024 14:15:24 +0200 Subject: [PATCH] Isolating dashboard tests to see if these are the last items to fix --- pkg/run/install/install_dashboard_test.go | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) diff --git a/pkg/run/install/install_dashboard_test.go b/pkg/run/install/install_dashboard_test.go index 830a8ccd41..1ab80b4196 100644 --- a/pkg/run/install/install_dashboard_test.go +++ b/pkg/run/install/install_dashboard_test.go @@ -195,7 +195,7 @@ var _ = Describe("InstallDashboard", func() { var _ = Describe("GetInstalledDashboard", func() { var ( fakeContext context.Context - //fakeClientWithHelmReleases client.WithWatch + // fakeClientWithHelmReleases client.WithWatch fakeClientWithDeployments client.WithWatch blankClient client.WithWatch errorClient ErroringFakeClient @@ -206,39 +206,39 @@ var _ = Describe("GetInstalledDashboard", func() { scheme, err := kube.CreateScheme() Expect(err).NotTo(HaveOccurred()) - //fakeClientWithHelmReleases = fake.NewClientBuilder().WithScheme(scheme).WithRuntimeObjects(helmReleaseFixtures...).Build() + // fakeClientWithHelmReleases = fake.NewClientBuilder().WithScheme(scheme).WithRuntimeObjects(helmReleaseFixtures...).Build() fakeClientWithDeployments = fake.NewClientBuilder().WithScheme(scheme).WithRuntimeObjects(deploymentFixtures...).Build() blankClient = fake.NewClientBuilder().WithScheme(scheme).Build() errorClient = ErroringFakeClient{} }) - //It("returns the oss dashboard type if the dashboard is installed with a helmrelease", func() { - // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ + // It("returns the oss dashboard type if the dashboard is installed with a helmrelease", func() { + // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ // DashboardTypeOSS: true, // }) // Expect(err).ToNot(HaveOccurred()) // Expect(dashboardType).To(Equal(DashboardTypeOSS)) // Expect(dashboardName).To(Equal("dashboard-2")) - //}) + // }) // - //It("returns the enterprise dashboard type if the dashboard is installed with a helmrelease", func() { - // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ + // It("returns the enterprise dashboard type if the dashboard is installed with a helmrelease", func() { + // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ // DashboardTypeEnterprise: true, // }) // Expect(err).ToNot(HaveOccurred()) // Expect(dashboardType).To(Equal(DashboardTypeEnterprise)) // Expect(dashboardName).To(Equal("dashboard-3")) - //}) + // }) // - //It("returns the enterprise dashboard type if both dashboards are installed with a helmrelease", func() { - // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ + // It("returns the enterprise dashboard type if both dashboards are installed with a helmrelease", func() { + // dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithHelmReleases, testNamespace, map[DashboardType]bool{ // DashboardTypeOSS: true, // DashboardTypeEnterprise: true, // }) // Expect(err).ToNot(HaveOccurred()) // Expect(dashboardType).To(Equal(DashboardTypeEnterprise)) // Expect(dashboardName).To(Equal("dashboard-3")) - //}) + // }) It("returns the oss dashboard type if the dashboard is installed with a deployment only", func() { dashboardType, dashboardName, err := GetInstalledDashboard(fakeContext, fakeClientWithDeployments, testNamespace, map[DashboardType]bool{