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 2023/02/27 17:30:20 UTC

[camel-k] 16/19: chore: move startup and teardown in support folder

This is an automated email from the ASF dual-hosted git repository.

pcongiusti pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel-k.git

commit b0f7c9619348cbac22e516065fa4631771e4d5c8
Author: Pasquale Congiusti <pa...@gmail.com>
AuthorDate: Mon Feb 27 10:24:01 2023 +0100

    chore: move startup and teardown in support folder
---
 e2e/common/cli/get_test.go                 | 2 +-
 e2e/common/cli/run_test.go                 | 4 ++--
 e2e/common/{ => support}/startup_test.go   | 2 +-
 e2e/common/{ => support}/teardown_test.go  | 2 +-
 e2e/knative/{ => support}/startup_test.go  | 2 +-
 e2e/knative/{ => support}/teardown_test.go | 2 +-
 script/Makefile                            | 8 ++++----
 script/get_catalog.sh                      | 2 +-
 8 files changed, 12 insertions(+), 12 deletions(-)

diff --git a/e2e/common/cli/get_test.go b/e2e/common/cli/get_test.go
index 1d404045e..78bb1d9a2 100644
--- a/e2e/common/cli/get_test.go
+++ b/e2e/common/cli/get_test.go
@@ -55,7 +55,7 @@ func TestKamelCLIGet(t *testing.T) {
 		Eventually(IntegrationPodPhase(ns, "yaml"), TestTimeoutLong).Should(Equal(corev1.PodRunning))
 		Eventually(IntegrationPodPhase(ns, "java"), TestTimeoutLong).Should(Equal(corev1.PodRunning))
 
-		Eventually(IntegrationKit(ns, "yajavaml")).ShouldNot(Equal(""))
+		Eventually(IntegrationKit(ns, "java")).ShouldNot(Equal(""))
 		Eventually(IntegrationKit(ns, "yaml")).ShouldNot(Equal(""))
 		kitName1 := IntegrationKit(ns, "java")()
 		kitName2 := IntegrationKit(ns, "yaml")()
diff --git a/e2e/common/cli/run_test.go b/e2e/common/cli/run_test.go
index 161223684..280e3430a 100644
--- a/e2e/common/cli/run_test.go
+++ b/e2e/common/cli/run_test.go
@@ -44,7 +44,7 @@ func TestKamelCLIRun(t *testing.T) {
 	t.Run("Examples from GitHub", func(t *testing.T) {
 		t.Run("Java", func(t *testing.T) {
 			Expect(KamelRunWithID(operatorID, ns,
-				"github:apache/camel-k-examples/blob/main/generic-examples/languages/Sample.java").Execute()).To(Succeed())
+				"github:apache/camel-k-examples/generic-examples/languages/Sample.java").Execute()).To(Succeed())
 			Eventually(IntegrationPodPhase(ns, "sample"), TestTimeoutLong).Should(Equal(corev1.PodRunning))
 			Eventually(IntegrationConditionStatus(ns, "sample", v1.IntegrationConditionReady), TestTimeoutShort).
 				Should(Equal(corev1.ConditionTrue))
@@ -65,7 +65,7 @@ func TestKamelCLIRun(t *testing.T) {
 
 		t.Run("Java (branch)", func(t *testing.T) {
 			Expect(KamelRunWithID(operatorID, ns,
-				"github:apache/camel-k-examples/blob/main/generic-examples/languages/Sample.java?branch=main").Execute()).To(Succeed())
+				"github:apache/camel-k-examples/generic-examples/languages/Sample.java?branch=main").Execute()).To(Succeed())
 			Eventually(IntegrationPodPhase(ns, "sample"), TestTimeoutLong).Should(Equal(corev1.PodRunning))
 			Eventually(IntegrationConditionStatus(ns, "sample", v1.IntegrationConditionReady), TestTimeoutShort).
 				Should(Equal(corev1.ConditionTrue))
diff --git a/e2e/common/startup_test.go b/e2e/common/support/startup_test.go
similarity index 99%
rename from e2e/common/startup_test.go
rename to e2e/common/support/startup_test.go
index c8a3ad9af..b1707383e 100644
--- a/e2e/common/startup_test.go
+++ b/e2e/common/support/startup_test.go
@@ -20,7 +20,7 @@ See the License for the specific language governing permissions and
 limitations under the License.
 */
 
-package common
+package support
 
 import (
 	"testing"
diff --git a/e2e/common/teardown_test.go b/e2e/common/support/teardown_test.go
similarity index 98%
rename from e2e/common/teardown_test.go
rename to e2e/common/support/teardown_test.go
index fcc67b0f5..064b44777 100644
--- a/e2e/common/teardown_test.go
+++ b/e2e/common/support/teardown_test.go
@@ -20,7 +20,7 @@ See the License for the specific language governing permissions and
 limitations under the License.
 */
 
-package common
+package support
 
 import (
 	"testing"
diff --git a/e2e/knative/startup_test.go b/e2e/knative/support/startup_test.go
similarity index 99%
rename from e2e/knative/startup_test.go
rename to e2e/knative/support/startup_test.go
index 4bab6ed40..6e1260f59 100644
--- a/e2e/knative/startup_test.go
+++ b/e2e/knative/support/startup_test.go
@@ -20,7 +20,7 @@ See the License for the specific language governing permissions and
 limitations under the License.
 */
 
-package knative
+package support
 
 import (
 	"testing"
diff --git a/e2e/knative/teardown_test.go b/e2e/knative/support/teardown_test.go
similarity index 98%
rename from e2e/knative/teardown_test.go
rename to e2e/knative/support/teardown_test.go
index ac0504d82..1a141d657 100644
--- a/e2e/knative/teardown_test.go
+++ b/e2e/knative/support/teardown_test.go
@@ -20,7 +20,7 @@ See the License for the specific language governing permissions and
 limitations under the License.
 */
 
-package knative
+package support
 
 import (
 	"testing"
diff --git a/script/Makefile b/script/Makefile
index 7419e570b..34879a604 100644
--- a/script/Makefile
+++ b/script/Makefile
@@ -255,13 +255,13 @@ test-fmt: do-build
 #
 test-common: do-build
 	FAILED=0; STAGING_RUNTIME_REPO="$(STAGING_RUNTIME_REPO)"; \
-	go test -timeout 30m -v ./e2e/common/startup_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
+	go test -timeout 30m -v ./e2e/common/support/startup_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 30m -v ./e2e/common/languages -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 30m -v ./e2e/common/cli -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 30m -v ./e2e/common/config -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 30m -v ./e2e/common/misc -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 30m -v ./e2e/common/traits -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
-	go test -timeout 30m -v ./e2e/common/teardown_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
+	go test -timeout 30m -v ./e2e/common/support/teardown_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	exit $${FAILED}
 
 #
@@ -297,9 +297,9 @@ test-install-upgrade: do-build
 #
 test-knative: do-build
 	STAGING_RUNTIME_REPO="$(STAGING_RUNTIME_REPO)" \
-	go test -timeout 30m -v ./e2e/knative/startup_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
+	go test -timeout 30m -v ./e2e/knative/support/startup_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	go test -timeout 60m -v ./e2e/knative -tags=integration $(TEST_KNATIVE_RUN) $(GOTESTFMT) || FAILED=1; \
-	go test -timeout 30m -v ./e2e/knative/teardown_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
+	go test -timeout 30m -v ./e2e/knative/support/teardown_test.go -tags=integration $(TEST_INTEGRATION_COMMON_LANG_RUN) $(GOTESTFMT) || FAILED=1; \
 	exit $${FAILED}
 
 #
diff --git a/script/get_catalog.sh b/script/get_catalog.sh
index 0a4b5ded1..85d4d7b33 100755
--- a/script/get_catalog.sh
+++ b/script/get_catalog.sh
@@ -15,7 +15,7 @@
 # See the License for the specific language governing permissions and
 # limitations under the License.
 
-set -ex
+set -e
 
 location=$(dirname $0)
 rootdir=$location/../