Skip to content

Commit

Permalink
regenerate mocks
Browse files Browse the repository at this point in the history
  • Loading branch information
bakito committed Mar 8, 2021
1 parent 6df87d5 commit b66afa7
Show file tree
Hide file tree
Showing 10 changed files with 157 additions and 173 deletions.
27 changes: 22 additions & 5 deletions .github/workflows/build.yml
Expand Up @@ -13,10 +13,10 @@ jobs:
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.14
- name: Set up Go 1.1x
uses: actions/setup-go@v2
with:
go-version: ^1.14
go-version: ^1.15
id: go

- name: Check out code into the Go module directory
Expand All @@ -31,8 +31,25 @@ jobs:
- name: Verify Helm Chart
run: make helm-template

- name: Test Release
run: make test-release

- name: Build the Docker image
run: make build-docker


test-release:
name: test release
runs-on: ubuntu-latest
steps:

- name: Set up Go 1.x
uses: actions/setup-go@v2
with:
go-version: ^1.15

- name: Check out code into the Go module directory
uses: actions/checkout@v2

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
with:
version: latest
args: --skip-publish --snapshot --rm-dist
1 change: 0 additions & 1 deletion .goreleaser.yml
@@ -1,7 +1,6 @@
before:
hooks:
- helm package ./helm/example-batch-job-controller/ --version v{{ .Version }} --app-version v{{ .Version }} -d ./
- make licenses
builds:
- skip: true
main: ./cmd/generic/main.go
Expand Down
25 changes: 3 additions & 22 deletions Makefile
Expand Up @@ -22,14 +22,10 @@ tidy:
go mod tidy

# Run tests
test: mocks tidy fmt vet
test: tidy mocks fmt vet
go test ./... -coverprofile=coverage.out
go tool cover -func=coverage.out

# Run ci tests
test-ci: test
goveralls -service=travis-ci -v -coverprofile=coverage.out

# Run tests
helm-template: helm
helm template helm/example-batch-job-controller/ --debug --set routes.hostSuffix=test.com
Expand All @@ -48,31 +44,16 @@ release: goreleaser
test-release: goreleaser
goreleaser --skip-publish --snapshot --rm-dist

licenses: go-licenses
go-licenses csv "github.com/bakito/batch-job-controller/cmd/generic" 2>/dev/null | sort > ./dependency-licenses.csv

tools: mockgen ginkgo helm goveralls goreleaser go-licenses
tools: mockgen ginkgo helm

mockgen:
ifeq (, $(shell which mockgen))
$(shell go get github.com/golang/mock/mockgen@v1.4.3)
$(shell go get github.com/golang/mock/mockgen)
endif
ginkgo:
ifeq (, $(shell which ginkgo))
$(shell go get github.com/onsi/ginkgo/ginkgo)
endif
goveralls:
ifeq (, $(shell which goveralls))
$(shell go get github.com/mattn/goveralls)
endif
go-licenses:
ifeq (, $(shell which go-licenses))
$(shell go get github.com/google/go-licenses)
endif
goreleaser:
ifeq (, $(shell which goreleaser))
$(shell go get github.com/goreleaser/goreleaser)
endif
helm:
ifeq (, $(shell which helm))
$(shell curl https://raw.githubusercontent.com/helm/helm/master/scripts/get-helm-3 | bash)
Expand Down
4 changes: 2 additions & 2 deletions go.mod
Expand Up @@ -7,11 +7,11 @@ require (
github.com/go-logr/logr v0.4.0
github.com/go-logr/zapr v0.4.0
github.com/go-playground/validator/v10 v10.4.1
github.com/golang/mock v1.5.0
github.com/golang/mock v1.4.3
github.com/google/uuid v1.2.0
github.com/gorilla/mux v1.8.0
github.com/onsi/ginkgo v1.15.1
github.com/onsi/gomega v1.10.5
github.com/onsi/gomega v1.11.0
github.com/prometheus/client_golang v1.9.0
github.com/prometheus/common v0.18.0
github.com/robfig/cron/v3 v3.0.1
Expand Down
36 changes: 9 additions & 27 deletions go.sum

Large diffs are not rendered by default.

59 changes: 30 additions & 29 deletions pkg/mocks/client/mock.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit b66afa7

Please sign in to comment.