From ba5a39d341694bc106280af9c2f9b0864f58511e Mon Sep 17 00:00:00 2001 From: ricardodalarme Date: Mon, 27 Mar 2023 23:36:15 -0300 Subject: [PATCH] chore(ci): add code coverage report --- .github/workflows/code-check.yml | 11 +++++++++-- README.md | 5 +++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/.github/workflows/code-check.yml b/.github/workflows/code-check.yml index 1050cad..35f4480 100644 --- a/.github/workflows/code-check.yml +++ b/.github/workflows/code-check.yml @@ -22,8 +22,15 @@ jobs: channel: "stable" cache: true - - name: Run Flutter Test - run: flutter test + - name: Run Flutter Test Coverage + run: flutter test --coverage + + - name: Upload Coverage to Codecov + if: github.event_name == 'push' + uses: codecov/codecov-action@v3 + with: + files: ./coverage/lcov.info + fail_ci_if_error: true lint: name: Lint diff --git a/README.md b/README.md index 40c1ddc..2a39cb1 100644 --- a/README.md +++ b/README.md @@ -1,10 +1,11 @@ # flutter_card_swiper [![Pub Version](https://img.shields.io/pub/v/flutter_card_swiper?logo=dart&logoColor=white)](https://pub.dev/packages/flutter_card_swiper) -[![Pub points](https://badgen.net/pub/points/flutter_card_swiper)](https://pub.dev/packages/flutter_card_swiper) +[![Pub Points](https://badgen.net/pub/points/flutter_card_swiper)](https://pub.dev/packages/flutter_card_swiper) [![Pub Likes](https://badgen.net/pub/likes/flutter_card_swiper)](https://pub.dev/packages/flutter_card_swiper) [![Pub popularity](https://badgen.net/pub/popularity/flutter_card_swiper)](https://pub.dev/packages/flutter_card_swiper) -[![License](https://badgen.net/github/license/ricardodalarme/flutter_card_swiper)](https://github.com/ricardodalarme/flutter_card_swiper/blob/main/LICENSE) +[![Tests](https://github.com/ricardodalarme/flutter_card_swiper/actions/workflows/code-check.yml/badge.svg)](https://github.com/ricardodalarme/flutter_card_swiper/actions/workflows/code-check.yml) +[![codecov](https://codecov.io/gh/ricardodalarme/flutter_card_swiper/branch/main/graph/badge.svg?token=UW677LGCBF)](https://codecov.io/gh/ricardodalarme/flutter_card_swiper) This is a Flutter package for a Tinder-like card swiper. ✨