Skip to content

Commit fa5de3b

Browse files
feat(CI): add check for example plugins
1 parent 62800c1 commit fa5de3b

File tree

1 file changed

+29
-1
lines changed

1 file changed

+29
-1
lines changed

.github/workflows/ci.yaml

Lines changed: 29 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ concurrency:
1111
cancel-in-progress: true
1212

1313
jobs:
14-
setup-build:
14+
build-lint-and-test:
1515
runs-on: ubuntu-latest
1616
steps:
1717
- name: Checkout code
@@ -50,3 +50,31 @@ jobs:
5050
- name: Lint code (staticcheck)
5151
run: staticcheck ./...
5252
working-directory: src
53+
54+
check-example-plugins:
55+
runs-on: ubuntu-latest
56+
steps:
57+
- name: Checkout code
58+
uses: actions/checkout@v4
59+
60+
- name: Set up Go
61+
uses: actions/setup-go@v4
62+
with:
63+
go-version: 1.22
64+
cache-dependency-path: src/go.sum
65+
66+
- name: Verify dependencies (for zoraxy)
67+
run: go mod verify
68+
working-directory: src
69+
70+
- name: Install dependencies (for zoraxy)
71+
run: go mod tidy
72+
working-directory: src
73+
74+
- name: Example plugins are up to date and build successfully
75+
run: |
76+
bash build-all.sh && git diff --exit-code # if code fails to build, or if there are code changes, this step will fail
77+
working-directory: example/plugins
78+
79+
# TODO: if possible, it may be good to test whether the plugins correctly
80+
# report their introspection data when run with the -introspect flag.

0 commit comments

Comments
 (0)