From a37c37b8f5f3a426bcaa2d90ecec353a4ca40f61 Mon Sep 17 00:00:00 2001 From: Dzmitry Malyshau Date: Thu, 6 May 2021 12:24:57 -0400 Subject: [PATCH] Integrate codecov on CI --- .github/workflows/lazy.yml | 28 ++++++++++++++++++++++++++++ .github/workflows/pipeline.yml | 1 + README.md | 1 + 3 files changed, 30 insertions(+) create mode 100644 .github/workflows/lazy.yml diff --git a/.github/workflows/lazy.yml b/.github/workflows/lazy.yml new file mode 100644 index 000000000..7344fdac0 --- /dev/null +++ b/.github/workflows/lazy.yml @@ -0,0 +1,28 @@ +# Lazy jobs running on master post merges. +name: lazy +on: + push: + branches: [master] + +jobs: + coverage: + name: Coverage + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + - uses: actions-rs/toolchain@v1 + with: + toolchain: stable + - name: Generate report + uses: actions-rs/tarpaulin@v0.1 + with: + args: '--tests --all-features' + - name: Upload to codecov.io + uses: codecov/codecov-action@v1 + with: + token: ${{ secrets.CODECOV_TOKEN }} + - name: Archive code coverage results + uses: actions/upload-artifact@v1 + with: + name: code-coverage-report + path: cobertura.xml diff --git a/.github/workflows/pipeline.yml b/.github/workflows/pipeline.yml index 3d9ca0f6a..57d80e5a2 100644 --- a/.github/workflows/pipeline.yml +++ b/.github/workflows/pipeline.yml @@ -1,3 +1,4 @@ +# Regular testing. name: pipeline on: [push, pull_request] diff --git a/README.md b/README.md index 3772b9d2a..6b0adf349 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ [![Crates.io](https://img.shields.io/crates/v/naga.svg?label=naga)](https://crates.io/crates/naga) [![Docs.rs](https://docs.rs/naga/badge.svg)](https://docs.rs/naga) [![Build Status](https://github.com/gfx-rs/naga/workflows/pipeline/badge.svg)](https://github.com/gfx-rs/naga/actions) +[![codecov.io](https://codecov.io/gh/gfx-rs/naga/branch/master/graph/badge.svg?token=9VOKYO8BM2)](https://codecov.io/gh/gfx-rs/naga) The shader translation library for the needs of [wgpu](https://github.com/gfx-rs/wgpu) and [gfx-rs](https://github.com/gfx-rs/gfx) projects.