diff --git a/.github/workflows/e2e.yaml b/.github/workflows/e2e.yaml index 59cae4bb92..bb5b33120e 100644 --- a/.github/workflows/e2e.yaml +++ b/.github/workflows/e2e.yaml @@ -1,7 +1,10 @@ name: e2e-tests -on: pull_request +on: + pull_request: + push: + branches: [ main ] env: # Make sure to exit early if cache segment download times out after 2 minutes. diff --git a/Makefile b/Makefile index d52ff1c8bb..ea00ecb362 100644 --- a/Makefile +++ b/Makefile @@ -96,12 +96,12 @@ chlog-update: chlog-validate ## Creates an update to CHANGELOG.md for a release $(CHLOGGEN) update --version "[$(VERSION)] - $$(date +'%Y-%m-%d')" || exit 1; \ ci_scripts/chloggen-update.sh || exit 1 -CERTMANAGER_VERSION ?= 1.10.0 +CERTMANAGER_VERSION ?= $(shell yq eval ".dependencies[] | select(.name == \"cert-manager\") | .version" helm-charts/splunk-otel-collector/Chart.yaml) .PHONY: cert-manager cert-manager: cmctl # Consider using cmctl to install the cert-manager once install command is not experimental - kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/v${CERTMANAGER_VERSION}/cert-manager.yaml + kubectl apply --validate=false -f https://github.com/jetstack/cert-manager/releases/download/${CERTMANAGER_VERSION}/cert-manager.yaml $(CMCTL) check api --wait=5m PROJECT_DIR := $(shell dirname $(abspath $(lastword $(MAKEFILE_LIST)))) @@ -114,7 +114,7 @@ cmctl: exit 0; \ fi ;\ TMP_DIR=$$(mktemp -d) ;\ - curl -L -o $$TMP_DIR/cmctl.tar.gz https://github.com/jetstack/cert-manager/releases/download/v$(CERTMANAGER_VERSION)/cmctl-`go env GOOS`-`go env GOARCH`.tar.gz ;\ + curl -L -o $$TMP_DIR/cmctl.tar.gz https://github.com/jetstack/cert-manager/releases/download/$(CERTMANAGER_VERSION)/cmctl-`go env GOOS`-`go env GOARCH`.tar.gz ;\ tar xzf $$TMP_DIR/cmctl.tar.gz -C $$TMP_DIR ;\ [ -d bin ] || mkdir bin ;\ mv $$TMP_DIR/cmctl $(CMCTL) ;\ diff --git a/e2e_tests/e2e_test.go b/e2e_tests/e2e_test.go index 2cc5af3a43..de5351b828 100644 --- a/e2e_tests/e2e_test.go +++ b/e2e_tests/e2e_test.go @@ -161,11 +161,6 @@ func Test_E2E(t *testing.T) { latestTrace := tracesConsumer.AllTraces()[len(tracesConsumer.AllTraces())-1] actualSpan := latestTrace.ResourceSpans().At(0).ScopeSpans().At(0).Spans().At(0) - host, _ := actualSpan.Attributes().Get("http.host") - assert.Equal(t, "localhost:3000", host.AsString()) - - statusCode, _ := actualSpan.Attributes().Get("http.status_code") - assert.Equal(t, "200", statusCode.AsString()) expectedSpan := expectedTraces.ResourceSpans().At(0).ScopeSpans().At(0).Spans().At(0) expectedSpan.Attributes().Range(func(k string, _ pcommon.Value) bool {