Skip to content

Commit

Permalink
Merge pull request #22 from pelotech/add-tests-to-ci
Browse files Browse the repository at this point in the history
Add unit/integration tests to CI build
  • Loading branch information
josmo authored Aug 13, 2024
2 parents 0ebc82b + b873ef6 commit b527b75
Show file tree
Hide file tree
Showing 3 changed files with 37 additions and 18 deletions.
37 changes: 37 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
name: build
on:
push:
branches:
- main
pull_request:
branches:
- main

jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: install pre-commit
run: pip install pre-commit
- name: pre-commit
run: pre-commit run --all-files --show-diff-on-failure

build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get kubebuilder
uses: RyanSiu1995/[email protected]
with:
version: 4.1.1
- name: Setup Go
uses: actions/setup-go@v5
with:
go-version: '1.21.x'
- name: Display Go version
run: go version
- name: Build manager library
run: go build -o bin/manager github.com/uswitch/nidhogg/cmd/manager
- name: Run tests
run: go test ./pkg/... ./cmd/...
18 changes: 0 additions & 18 deletions .github/workflows/pre-commit.yaml

This file was deleted.

File renamed without changes.

0 comments on commit b527b75

Please sign in to comment.