Repository navigation
67 lines (58 loc) · 2.28 KB
/
Copy pathe2e.yml
File metadata and controls
67 lines (58 loc) · 2.28 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
name: E2E
on:
pull_request:
branches:
- master
paths-ignore:
- 'docs/**'
- 'charts/**'
- '*.md'
- '.gitignore'
- '.editorconfig'
- 'renovate.json'
- '.github/**'
- '!.github/workflows/e2e.yml'
jobs:
e2e-test:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
group:
- name: basic
tests: "test-01-lint.bats test-02-deployment.bats test-03-backup.bats test-04-restore.bats"
- name: annotated
tests: "test-05-annotated-backup.bats test-08-restore-backupcommand.bats"
- name: rwo-and-pods
tests: "test-06-pvc-rwo.bats test-09-pod-backupcommand.bats"
- name: tls
tests: "test-10-restore-self-signed-tls.bats test-11-archive-self-signed-tls.bats"
- name: misc
tests: "test-12-annotated-failure.bats test-13-cleanup-empty-jobs.bats test-15-backup-with-selectors.bats"
name: e2e (${{ matrix.group.name }})
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7
- name: Determine Go version from go.mod
run: echo "GO_VERSION=$(go mod edit -json | jq -r .Go)" >> $GITHUB_ENV
- uses: actions/setup-go@924ae3a1cded613372ab5595356fb5720e22ba16 # v6
with:
go-version: ${{ env.GO_VERSION }}
- name: Run e2e tests
run: make crd e2e-test -e KIND_KUBECTL_ARGS=--validate=false -e bats_args="--report-formatter junit" -e BATS_FILES="${{ matrix.group.tests }}"
- name: Retry failed e2e tests
if: failure()
run: make e2e-test -e KIND_KUBECTL_ARGS=--validate=false -e bats_args="--report-formatter junit" -e BATS_FILES="${{ matrix.group.tests }}"
- name: Collect debug info on failure
if: failure()
run: |
echo "=== Pod status ==="
kubectl get pods -A --no-headers | grep -v Running || true
echo "=== Recent events ==="
kubectl get events -A --sort-by='.lastTimestamp' | tail -20 || true
- name: Publish Test Report
uses: mikepenz/action-junit-report@6ef3fdcfcd5f0b5d14df3e659ef19b8c6820f93d # v6
if: success() || failure()
with:
report_paths: '**/e2e/report.xml'
github_token: ${{ secrets.GITHUB_TOKEN }}
check_name: e2e-report (${{ matrix.group.name }})