Skip to content

Commit 9b72920

Browse files
authored
Merge pull request #117 from nasusoba/prblocker
Add a github workflow to enable e2e for PR blocker
2 parents 429d569 + 772ca74 commit 9b72920

File tree

1 file changed

+50
-0
lines changed

1 file changed

+50
-0
lines changed

.github/workflows/e2e-pr.yaml

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
name: E2E tests (PR Blocker)
2+
on:
3+
pull_request:
4+
types: [opened, synchronize, reopened]
5+
workflow_dispatch:
6+
7+
env:
8+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
9+
10+
jobs:
11+
e2e-tests:
12+
runs-on: ubuntu-latest
13+
steps:
14+
- name: Free Disk Space
15+
uses: jlumbroso/free-disk-space@main
16+
with:
17+
tool-cache: false
18+
docker-images: false
19+
- name: Checkout code
20+
uses: actions/checkout@v4
21+
with:
22+
fetch-depth: 0
23+
- name: Install Go
24+
uses: actions/setup-go@v5
25+
with:
26+
go-version-file: go.mod
27+
cache: true
28+
- name: Build e2e image
29+
run: make docker-build-e2e
30+
- uses: actions/[email protected]
31+
with:
32+
path: |
33+
~/go/pkg/mod
34+
~/.cache/go-build
35+
key: ${{ runner.os }}-test-go-${{ hashFiles('**/go.sum') }}
36+
restore-keys: |
37+
${{ runner.os }}-test-go-${{ hashFiles('**/go.sum') }}
38+
- uses: engineerd/[email protected]
39+
with:
40+
version: "v0.22.0"
41+
skipClusterCreation: "true"
42+
- name: Run E2E tests
43+
run: make GINKGO_FOCUS="\\[PR-Blocking\\]" test-e2e
44+
- name: Archive artifacts
45+
if: always()
46+
uses: actions/[email protected]
47+
with:
48+
name: e2e-artifacts
49+
path: _artifacts
50+
if-no-files-found: ignore

0 commit comments

Comments
 (0)