From 73d355a0a61b4b2d212fe2b3f8b4263a31b4c7ed Mon Sep 17 00:00:00 2001 From: Joel Smith Date: Thu, 7 Mar 2024 08:17:24 -0700 Subject: [PATCH] e2e: Don't try to remove opentelemetry if not installed Signed-off-by: Joel Smith --- CHANGELOG.md | 2 +- tests/utils/cleanup_test.go | 4 ++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index de429fa370a..24cc2078c21 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -86,7 +86,7 @@ New deprecation(s): ### Other - **General**: Improve readability of utility function getParameterFromConfigV2 ([#5037](https://github.com/kedacore/keda/issues/5037)) -- **General**: Introduce ENABLE_OPENTELEMETRY in deploying/testing process ([#5375](https://github.com/kedacore/keda/issues/5375)) +- **General**: Introduce ENABLE_OPENTELEMETRY in deploying/testing process ([#5375](https://github.com/kedacore/keda/issues/5375), [#5578](https://github.com/kedacore/keda/issues/5578)) - **General**: Migrate away from unmaintained golang/mock and use uber/gomock ([#5440](https://github.com/kedacore/keda/issues/5440)) - **General**: Minor refactor to reduce copy/paste code in ScaledObject webhook ([#5397](https://github.com/kedacore/keda/issues/5397)) diff --git a/tests/utils/cleanup_test.go b/tests/utils/cleanup_test.go index f0d8b0a627b..422102fe054 100644 --- a/tests/utils/cleanup_test.go +++ b/tests/utils/cleanup_test.go @@ -65,6 +65,10 @@ func TestRemoveGcpIdentityComponents(t *testing.T) { } func TestRemoveOpentelemetryComponents(t *testing.T) { + if EnableOpentelemetry == "" || EnableOpentelemetry == StringFalse { + t.Skip("skipping uninstall of opentelemetry") + } + _, err := ExecuteCommand(fmt.Sprintf("helm uninstall opentelemetry-collector --namespace %s", OpentelemetryNamespace)) require.NoErrorf(t, err, "cannot uninstall opentelemetry-collector - %s", err) DeleteNamespace(t, OpentelemetryNamespace)