Skip to content

Commit

Permalink
Merge pull request #1 from whg517/chore/codecov
Browse files Browse the repository at this point in the history
chore: add codecov support
  • Loading branch information
whg517 authored Jul 12, 2024
2 parents e6755d2 + fc8b3f9 commit 1d45361
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 1 deletion.
7 changes: 7 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ jobs:

LINTER_RULES_PATH: /
MARKDOWN_CONFIG_FILE: .markdownlint.yml

golang-lint:
name: golang-lint
runs-on: ubuntu-latest
Expand Down Expand Up @@ -102,3 +103,9 @@ jobs:
- name: Go Test
run: |
make test
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4.0.1
with:
token: ${{ secrets.CODECOV_TOKEN }}


2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ vet: ## Run go vet against code.

.PHONY: test
test: generate fmt vet envtest ## Run tests.
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test $$(go list ./... | grep -v /e2e) -coverprofile cover.out
KUBEBUILDER_ASSETS="$(shell $(ENVTEST) use $(ENVTEST_K8S_VERSION) --bin-dir $(LOCALBIN) -p path)" go test $$(go list ./... | grep -v /e2e) -race -covermode atomic -coverprofile coverage.out

##@ Build Dependencies

Expand Down

0 comments on commit 1d45361

Please sign in to comment.