Github actions to test, build and push #4
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Test | |
on: | |
push: | |
branches: [ main ] | |
pull_request: | |
branches: [ main ] | |
env: | |
GO_VERSION: ~1.22 | |
jobs: | |
test: | |
name: unit and integration tests | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check out code into the Go module directory | |
uses: actions/checkout@v4 | |
- name: Install Go | |
uses: actions/setup-go@v5 | |
with: | |
go-version: ${{ env.GO_VERSION }} | |
check-latest: true | |
- name: Lint | |
run: make lint | |
- name: Unit tests | |
run: make test | |
- name: Build operator image | |
run: make docker-build | |
- name: Create KinD | |
uses: helm/kind-action@v1 | |
with: | |
cluster_name: 'kind' | |
- name: E2E tests | |
run: make test-e2e |