This is an automated email from the ASF dual-hosted git repository. tsato pushed a commit to branch main in repository https://gitbox.apache.org/repos/asf/camel-k.git
commit 151def156ef0bcb8f4b05e95a2eb7de75cf111fd Author: Tadayoshi Sato <[email protected]> AuthorDate: Tue Sep 13 18:05:28 2022 +0900 fix(e2e): add E2E test for reconcilation of integrations in initialisation failed condition --- e2e/global/common/integration_fail_test.go | 7 +++++++ e2e/global/common/operator_metrics_test.go | 5 +++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/e2e/global/common/integration_fail_test.go b/e2e/global/common/integration_fail_test.go index 0f498ac84..cf999630c 100644 --- a/e2e/global/common/integration_fail_test.go +++ b/e2e/global/common/integration_fail_test.go @@ -96,6 +96,13 @@ func TestBadRouteIntegration(t *testing.T) { // Kit shouldn't be created Consistently(IntegrationKit(ns, name), 10*time.Second).Should(BeEmpty()) + // Fixing the route should reconcile the Integration in Initialization Failed condition to Running + Expect(KamelRunWithID(operatorID, ns, "files/Java.java", "--name", name).Execute()).To(Succeed()) + Eventually(IntegrationPodPhase(ns, name), TestTimeoutLong).Should(Equal(corev1.PodRunning)) + Eventually(IntegrationConditionStatus(ns, name, v1.IntegrationConditionReady), TestTimeoutShort). + Should(Equal(corev1.ConditionTrue)) + Eventually(IntegrationLogs(ns, name), TestTimeoutShort).Should(ContainSubstring("Magicstring!")) + // Clean up Expect(Kamel("delete", "--all", "-n", ns).Execute()).To(Succeed()) }) diff --git a/e2e/global/common/operator_metrics_test.go b/e2e/global/common/operator_metrics_test.go index c0c1e9ed5..db24f0f62 100644 --- a/e2e/global/common/operator_metrics_test.go +++ b/e2e/global/common/operator_metrics_test.go @@ -65,8 +65,9 @@ func TestMetrics(t *testing.T) { "-t", "prometheus.pod-monitor=false", ).Execute()).To(Succeed()) Eventually(IntegrationPodPhase(ns, name), TestTimeoutLong).Should(Equal(corev1.PodRunning)) - Eventually(IntegrationConditionStatus(ns, name, v1.IntegrationConditionReady), TestTimeoutShort).Should(Equal(corev1.ConditionTrue)) - Eventually(IntegrationLogs(ns, "java"), TestTimeoutShort).Should(ContainSubstring("Magicstring!")) + Eventually(IntegrationConditionStatus(ns, name, v1.IntegrationConditionReady), TestTimeoutShort). + Should(Equal(corev1.ConditionTrue)) + Eventually(IntegrationLogs(ns, name), TestTimeoutShort).Should(ContainSubstring("Magicstring!")) pod := OperatorPod(ns)() Expect(pod).NotTo(BeNil())
