You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by pc...@apache.org on 2022/08/11 10:30:15 UTC
[camel-k] branch release-1.9.x updated: Test operator image installed by the OLM
This is an automated email from the ASF dual-hosted git repository.
pcongiusti pushed a commit to branch release-1.9.x
in repository https://gitbox.apache.org/repos/asf/camel-k.git
The following commit(s) were added to refs/heads/release-1.9.x by this push:
new 01230b292 Test operator image installed by the OLM
01230b292 is described below
commit 01230b292c82f10646bd92cb4a41145b97950b3b
Author: Jan Bouska <jb...@redhat.com>
AuthorDate: Wed Aug 10 08:38:20 2022 +0200
Test operator image installed by the OLM
---
e2e/upgrade/olm_upgrade_test.go | 1 +
pkg/util/defaults/defaults_support.go | 5 +++++
2 files changed, 6 insertions(+)
diff --git a/e2e/upgrade/olm_upgrade_test.go b/e2e/upgrade/olm_upgrade_test.go
index 7aea85f5d..76012a0b9 100644
--- a/e2e/upgrade/olm_upgrade_test.go
+++ b/e2e/upgrade/olm_upgrade_test.go
@@ -153,6 +153,7 @@ func TestOLMAutomaticUpgrade(t *testing.T) {
Expect(prevCSVVersion.Version.String()).NotTo(Equal(newCSVVersion.Version.String()))
Eventually(OperatorPodPhase(ns), TestTimeoutMedium).Should(Equal(corev1.PodRunning))
+ Eventually(OperatorImage(ns), TestTimeoutShort).Should(Equal(defaults.OperatorImage()))
// Check the IntegrationPlatform has been reconciled
Eventually(PlatformVersion(ns)).Should(ContainSubstring(newIPVersionPrefix))
diff --git a/pkg/util/defaults/defaults_support.go b/pkg/util/defaults/defaults_support.go
index 3eab69a58..71b890bb9 100644
--- a/pkg/util/defaults/defaults_support.go
+++ b/pkg/util/defaults/defaults_support.go
@@ -18,6 +18,7 @@ limitations under the License.
package defaults
import (
+ "fmt"
"os"
"strconv"
@@ -28,6 +29,10 @@ func BaseImage() string {
return envOrDefault(baseImage, "KAMEL_BASE_IMAGE", "RELATED_IMAGE_BASE")
}
+func OperatorImage() string {
+ return envOrDefault(fmt.Sprintf("%s:%s", ImageName, Version), "KAMEL_OPERATOR_IMAGE", "KAMEL_K_TEST_OPERATOR_CURRENT_IMAGE")
+}
+
func InstallDefaultKamelets() bool {
return boolEnvOrDefault(installDefaultKamelets, "KAMEL_INSTALL_DEFAULT_KAMELETS")
}