From 055591e05edf736aa5332e7f048b5f693ccf3962 Mon Sep 17 00:00:00 2001 From: Chunyi Lyu Date: Thu, 15 Jul 2021 09:20:59 +0100 Subject: [PATCH 1/3] Remove k8s 1.18 from PR system tests --- .github/workflows/pr.yml | 1 - 1 file changed, 1 deletion(-) diff --git a/.github/workflows/pr.yml b/.github/workflows/pr.yml index 1b0161a39..6cf285933 100644 --- a/.github/workflows/pr.yml +++ b/.github/workflows/pr.yml @@ -52,7 +52,6 @@ jobs: strategy: matrix: k8s: - - v1.18.19 - v1.19.11 - v1.20.7 - v1.21.1 From c12e58ee076a6acbd90247fda3dfb2c26b60f117 Mon Sep 17 00:00:00 2001 From: Chunyi Lyu Date: Mon, 19 Jul 2021 10:42:03 +0100 Subject: [PATCH 2/3] Bump timeouts for configurations system tests --- system_tests/system_test.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/system_tests/system_test.go b/system_tests/system_test.go index 354ecf475..ae1082e10 100644 --- a/system_tests/system_test.go +++ b/system_tests/system_test.go @@ -165,14 +165,14 @@ var _ = Describe("Operator", func() { } Eventually(getConfigMapAnnotations, 30, 1).Should( HaveKey("rabbitmq.com/pluginsUpdatedAt"), "plugins ConfigMap should have been annotated") - Eventually(getConfigMapAnnotations, 60, 1).Should( + Eventually(getConfigMapAnnotations, 120, 1).Should( Not(HaveKey("rabbitmq.com/pluginsUpdatedAt")), "plugins ConfigMap annotation should have been removed") Eventually(func() map[string][]byte { secret, err := clientSet.CoreV1().Secrets(cluster.Namespace).Get(ctx, cluster.ChildResourceName("default-user"), metav1.GetOptions{}) Expect(err).NotTo(HaveOccurred()) return secret.Data - }).Should(HaveKeyWithValue("mqtt-port", []byte("1883"))) + }, 30).Should(HaveKeyWithValue("mqtt-port", []byte("1883"))) _, err := kubectlExec(namespace, statefulSetPodName(cluster, 0), From b68c8e445d5c12562459d0852b9c16322b19393c Mon Sep 17 00:00:00 2001 From: Chunyi Lyu Date: Mon, 19 Jul 2021 11:01:36 +0100 Subject: [PATCH 3/3] Add error descriptions to mqtt system tests --- system_tests/utils.go | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/system_tests/utils.go b/system_tests/utils.go index 95430e19d..7501f3f46 100644 --- a/system_tests/utils.go +++ b/system_tests/utils.go @@ -859,16 +859,16 @@ func publishAndConsumeMQTTMsg(hostname, port, username, password string, overWeb } token = c.Subscribe(topic, 0, handler) - ExpectWithOffset(1, token.Wait()).To(BeTrue()) - ExpectWithOffset(1, token.Error()).ToNot(HaveOccurred()) + ExpectWithOffset(1, token.Wait()).To(BeTrue(), "Subscribe token should return true") + ExpectWithOffset(1, token.Error()).ToNot(HaveOccurred(), "Subscribe token received error") token = c.Publish(topic, 0, false, "test message MQTT") - ExpectWithOffset(1, token.Wait()).To(BeTrue()) - ExpectWithOffset(1, token.Error()).ToNot(HaveOccurred()) + ExpectWithOffset(1, token.Wait()).To(BeTrue(), "Publish token should return true") + ExpectWithOffset(1, token.Error()).ToNot(HaveOccurred(), "Publish token received error") EventuallyWithOffset(1, func() bool { return msgReceived - }, 5*time.Second).Should(BeTrue()) + }, 5*time.Second).Should(BeTrue(), "Expect to receive message") token = c.Unsubscribe(topic) ExpectWithOffset(1, token.Wait()).To(BeTrue())