Skip to content

Commit

Permalink
tests/e2e: output runtime info for debugging purposes
Browse files Browse the repository at this point in the history
  • Loading branch information
iwilltry42 committed Jan 6, 2022
1 parent e2c20b8 commit 280de52
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 5 deletions.
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ GO_SRC += $(foreach dir,$(REC_DIRS),$(shell find $(dir) -name "*.go"))
########## Required Tools ##########
# Go Package required
PKG_GOX := github.com/mitchellh/[email protected]
PKG_GOLANGCI_LINT_VERSION := 1.39.0
PKG_GOLANGCI_LINT_VERSION := 1.43.0
PKG_GOLANGCI_LINT_SCRIPT := https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh
PKG_GOLANGCI_LINT := github.com/golangci/golangci-lint/cmd/golangci-lint@v${PKG_GOLANGCI_LINT_VERSION}

Expand Down
3 changes: 3 additions & 0 deletions tests/runner.sh
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,9 @@ source "$CURR_DIR/common.sh"

[ -n "$EXE" ] || abort "no EXE provided"

info "Checking test environment..."
$EXE runtime-info

info "Preparing filesystem and environment..."

export KUBECONFIG_ROOT="$HOME/.kube"
Expand Down
8 changes: 4 additions & 4 deletions tests/test_full_lifecycle.sh
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ check_multi_node "$clustername" 3 || failed "failed to verify number of nodes"

# 4. load an image into the cluster
info "Importing an image into the cluster..."
docker pull alpine:latest > /dev/null
docker tag alpine:latest alpine:local > /dev/null
docker pull alpine:3.15.0 > /dev/null
docker tag alpine:3.15.0 alpine:local > /dev/null
$EXE image import alpine:local -c $clustername || failed "could not import image in $clustername"

# 5. use imported image
Expand All @@ -90,9 +90,9 @@ wait_for_pod_running_by_label "k8s-app=kube-dns" "kube-system"
sleep 5

# 6. test host.k3d.internal
info "Checking DNS Lookup for host.k3d.internal..."
info "Checking DNS Lookup for host.k3d.internal via Ping..."
kubectl describe cm coredns -n kube-system | grep "host.k3d.internal" > /dev/null 2>&1 || failed "Couldn't find host.k3d.internal in CoreDNS configmap"
wait_for_pod_exec "testimage" "nslookup host.k3d.internal" 15 || failed "DNS Lookup for host.k3d.internal failed"
wait_for_pod_exec "testimage" "ping -c1 host.k3d.internal" 15 || failed "Pinging host.k3d.internal failed"

# Cleanup

Expand Down

0 comments on commit 280de52

Please sign in to comment.