Skip to content

fix: Fix generation problems and add more tests #12

fix: Fix generation problems and add more tests

fix: Fix generation problems and add more tests #12

Workflow file for this run

name: CI
on:
pull_request:
tags:
- v*
branches:
- main
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.21.x
cache: false
- uses: actions/checkout@v3
- name: golangci-lint
uses: golangci/golangci-lint-action@v3
with:
version: latest
args: '--config=.golangci.yaml -v'
- name: Check undetected changes
run: |-
REPO_STATUS="$(git status --porcelain)"
if [[ ! -z $REPO_STATUS ]]; then
echo "::error::Uncommitted changes detected"
echo "$REPO_STATUS"
git status -vv
exit 1
fi
test:
name: Test
runs-on: ubuntu-latest
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.21.x
- uses: actions/checkout@v3
- name: Run make test
run: make test
compile:
name: Build
runs-on: ubuntu-latest
steps:
- name: Install Go
uses: actions/setup-go@v4
with:
go-version: 1.21.x
- uses: actions/checkout@v3
- name: Run make generate deps compile test install
run: make generate deps compile test install
- name: Check undetected changes
run: |-
REPO_STATUS="$(git status --porcelain)"
if [[ ! -z $REPO_STATUS ]]; then
echo "::error::Uncommitted changes detected"
echo "$REPO_STATUS"
git status -vv
exit 1
fi
generate:
name: Generate
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Run make generate
run: make generate
- name: Check undetected changes
run: |-
REPO_STATUS="$(git status --porcelain)"
if [[ ! -z $REPO_STATUS ]]; then
echo "::error::Uncommitted changes detected"
echo "$REPO_STATUS"
git status -vv
exit 1
fi