Skip to content

Commit

Permalink
Generate presubmit coverage report using CodeCov (dapr#2072)
Browse files Browse the repository at this point in the history
* Add Codecov GitHub action.

* Only run Codecov when we run tests.

* Ignore more & cov only on linux-amd64 & add badge.

* Move CodeCov badge to same location as other badges.

* Formatting.

Co-authored-by: Young Bu Park <[email protected]>
  • Loading branch information
tcnghia and youngbupark authored Sep 18, 2020
1 parent a24e66e commit c1b10b3
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 10 deletions.
5 changes: 5 additions & 0 deletions .codecov.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
ignore:
- "**/zz_generated*.go" # Ignore generated files.
- "**/pkg/apis/**" # CRD related files including generated ones.
- "**/pkg/proto/**" # GRPC Protobuf client for dapr
- "**/pkg/testing/**" # testing mock
9 changes: 7 additions & 2 deletions .github/workflows/dapr.yml
Original file line number Diff line number Diff line change
Expand Up @@ -60,8 +60,13 @@ jobs:
if: matrix.target_arch != 'arm' && matrix.target_os != 'windows'
run: make lint
- name: Run make test
env:
COVERAGE_OPTS: "-coverprofile=coverage.txt -covermode=atomic"
if: matrix.target_arch != 'arm'
run: make test
- name: Codecov
if: matrix.target_arch == 'amd64' && matrix.target_os == 'linux'
uses: codecov/codecov-action@v1
- name: Run make release to build and archive binaries
run: |
mkdir -p ${{ env.ARCHIVE_OUTDIR }}
Expand Down Expand Up @@ -161,7 +166,7 @@ jobs:
tar xzvf $tgzfile -C $RELEASE_DIR
done
done
- name: publish binaries to github
if: startswith(github.ref, 'refs/tags/v')
run: |
Expand Down Expand Up @@ -259,5 +264,5 @@ jobs:
git config --global user.email "[email protected]"
git config --global user.name "dapr-bot"
git add --all
git commit -m "Release - $daprVersion"
git commit -m "Release - $daprVersion"
git push
2 changes: 1 addition & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ release: build archive
################################################################################
.PHONY: test
test:
go test ./pkg/...
go test ./pkg/... $(COVERAGE_OPTS)
go test ./tests/...

################################################################################
Expand Down
15 changes: 8 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

[![Go Report Card](https://goreportcard.com/badge/github.com/dapr/dapr)](https://goreportcard.com/report/github.com/dapr/dapr)
[![Build Status](https://github.com/dapr/dapr/workflows/dapr/badge.svg?event=push&branch=master)](https://github.com/dapr/dapr/actions?workflow=dapr)
[![codecov](https://codecov.io/gh/dapr/dapr/branch/master/graph/badge.svg)](https://codecov.io/gh/dapr/dapr)
[![Gitter](https://badges.gitter.im/Dapr/community.svg)](https://gitter.im/Dapr/community?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
[![License: MIT](https://img.shields.io/badge/License-MIT-yellow.svg)](https://opensource.org/licenses/MIT)
[![TODOs](https://badgen.net/https/api.tickgit.com/badgen/github.com/dapr/dapr)](https://www.tickgit.com/browse?repo=github.com/dapr/dapr)
Expand Down Expand Up @@ -72,8 +73,8 @@ See [Getting Started](https://github.com/dapr/docs/tree/master/getting-started).

## Quickstarts and Samples

* See the [quickstarts repository](https://github.com/dapr/quickstarts) for code examples that can help you get started with Dapr.
* Explore additional samples in the Dapr [samples repository](https://github.com/dapr/samples).
* See the [quickstarts repository](https://github.com/dapr/quickstarts) for code examples that can help you get started with Dapr.
* Explore additional samples in the Dapr [samples repository](https://github.com/dapr/samples).

## Community
We want your contributions and suggestions! One of the easiest ways to contribute is to participate in discussions on the mailing list, chat on IM or the bi-weekly community calls. Here is how to get involved:
Expand All @@ -84,7 +85,7 @@ Reach out with any questions you may have and we'll make sure to answer then as

| Platform | Link |
|:----------|:------------|
| 💬 Instant Message Chat (preferred) | https://gitter.im/Dapr/community
| 💬 Instant Message Chat (preferred) | https://gitter.im/Dapr/community
| 📧 Mailing List | https://groups.google.com/forum/#!forum/dapr-dev
| 🐤 Twitter | [@daprdev](https://twitter.com/daprdev)

Expand Down Expand Up @@ -114,8 +115,8 @@ Every two weeks we host a community call to showcase new features, review upcomi
|:-----------|:------------|
| 📺 Channel 9 | Azure Friday - Learn All About Distributed Application Runtime Dapr: [Part 1](https://channel9.msdn.com/Shows/Azure-Friday/Learn-all-about-Distributed-Application-Runtime-Dapr-Part-1) and [Part 2](https://channel9.msdn.com/Shows/Azure-Friday/Learn-all-about-Distributed-Application-Runtime-Dapr-Part-2)
| 🌎 Conferences | - [Dapr, Rudr, OAM: Mark Russinovich presents next gen app development & deployment](https://www.youtube.com/watch?v=eJCu6a-x9uo)<br>- [Mark Russinovich presents "The Future of Cloud Native Applications with OAM and Dapr"](https://myignite.techcommunity.microsoft.com/sessions/82059)<br>- [Build 2020: Mark Fussell presents Dapr](https://channel9.msdn.com/Events/Build/2020/INT118)
| 🎤 Hanselminutes | [Dapr Distributed Application Runtime with Mark Russinovich](https://hanselminutes.com/718/dapr-distributed-application-runtime-with-azure-cto-mark-russinovich)
| 💻 Azure Community Live | [Build microservice applications using DAPR with Mark Fussell ](https://www.youtube.com/watch?v=CgqI7nen-Ng)
| 🎤 Hanselminutes | [Dapr Distributed Application Runtime with Mark Russinovich](https://hanselminutes.com/718/dapr-distributed-application-runtime-with-azure-cto-mark-russinovich)
| 💻 Azure Community Live | [Build microservice applications using DAPR with Mark Fussell ](https://www.youtube.com/watch?v=CgqI7nen-Ng)

### Contributing to Dapr

Expand All @@ -136,8 +137,8 @@ See [Roadmap](https://github.com/dapr/dapr/wiki/Roadmap) for what's planned for
| [Docs](https://github.com/dapr/docs) | The documentation repository for Dapr.
| [Quickstarts](https://github.com/dapr/quickstarts) | This repository contains a series of simple code samples that highlight the main Dapr capabilities
| [Samples](https://github.com/dapr/samples) | This repository holds community maintained samples for various Dapr use cases.
| [Components-contrib ](https://github.com/dapr/components-contrib) | The purpose of components contrib is to provide open, community driven reusable components for building distributed applications.
| [Dashboard ](https://github.com/dapr/dashboard) | General purpose dashboard for Dapr
| [Components-contrib ](https://github.com/dapr/components-contrib) | The purpose of components contrib is to provide open, community driven reusable components for building distributed applications.
| [Dashboard ](https://github.com/dapr/dashboard) | General purpose dashboard for Dapr
| [Go-sdk](https://github.com/dapr/go-sdk) | Dapr SDK for Go
| [Java-sdk](https://github.com/dapr/java-sdk) | Dapr SDK for Java
| [JS-sdk](https://github.com/dapr/js-sdk) | Dapr SDK for JavaScript
Expand Down

0 comments on commit c1b10b3

Please sign in to comment.