Skip to content

Commit

Permalink
Move autoscale to its own test suite (#1733)
Browse files Browse the repository at this point in the history
  • Loading branch information
TylerHelmuth authored May 12, 2023
1 parent 625d1e0 commit 70e760e
Show file tree
Hide file tree
Showing 16 changed files with 19 additions and 3 deletions.
6 changes: 5 additions & 1 deletion .github/workflows/e2e.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,17 @@ jobs:
name: End-to-end tests
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
# The e2e tests are run on the lowest and highest supported k8s version.
# All Kubernetes version in between expose the same APIs, hence the operator
# should be compatible with them.
kube-version:
- "1.19"
- "1.26"
group:
- e2e e2e-upgrade
- e2e-autoscale

steps:

Expand All @@ -35,7 +39,7 @@ jobs:
- name: "run tests"
env:
KUBE_VERSION: ${{ matrix.kube-version }}
run: make prepare-e2e e2e e2e-upgrade KUBE_VERSION=$KUBE_VERSION VERSION=e2e
run: make prepare-e2e ${{ matrix.group }} KUBE_VERSION=$KUBE_VERSION VERSION=e2e

- name: "log operator if failed"
if: ${{ failure() }}
Expand Down
5 changes: 5 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -181,6 +181,11 @@ e2e:
e2e-upgrade: undeploy
$(KUTTL) test --config kuttl-test-upgrade.yaml

# end-to-end-test for testing autoscale
.PHONY: e2e-autoscale
e2e-autoscale:
$(KUTTL) test --config kuttl-test-autoscale.yaml

.PHONY: e2e-log-operator
e2e-log-operator:
kubectl get pod -n opentelemetry-operator-system | grep "opentelemetry-operator" | awk '{print $$1}' | xargs -I {} kubectl logs -n opentelemetry-operator-system {} manager
Expand Down
6 changes: 6 additions & 0 deletions kuttl-test-autoscale.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
apiVersion: kuttl.dev/v1beta1
kind: TestSuite
artifactsDir: ./tests/_build/artifacts/
testDirs:
- ./tests/e2e-autoscale/
timeout: 150
3 changes: 2 additions & 1 deletion kuttl-test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,5 @@ kind: TestSuite
artifactsDir: ./tests/_build/artifacts/
testDirs:
- ./tests/e2e/
timeout: 150
timeout: 150
parallel: 4
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ spec:
stabilizationWindowSeconds: 1
resources:
limits:
cpu: 250m
cpu: 100m
memory: 128Mi
requests:
cpu: 5m
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit 70e760e

Please sign in to comment.