Skip to content

Commit

Permalink
Merge branch 'master' of https://github.com/oalexandrefreire/MD5
Browse files Browse the repository at this point in the history
  • Loading branch information
oalexandrefreire committed Jul 24, 2024
2 parents f0e0d57 + b762a4d commit 9777f9d
Show file tree
Hide file tree
Showing 2 changed files with 54 additions and 0 deletions.
53 changes: 53 additions & 0 deletions .github/workflows/codecov.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,53 @@
name: Codecov Integration

on:
push:
branches:
- master
pull_request:
branches:
- master

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Checkout repository
uses: actions/checkout@v4

- name: Setup .NET Core
uses: actions/setup-dotnet@v4
with:
dotnet-version: '6.0.x'

- name: Restore dependencies
run: dotnet restore MD5CSharp/MD5.sln

- name: Build
run: dotnet build --no-restore MD5CSharp/MD5.sln

- name: Test
run: dotnet test --no-build --collect:"XPlat Code Coverage" MD5CSharp/MD5.sln

- name: Install ReportGenerator
run: dotnet tool install -g dotnet-reportgenerator-globaltool

- name: Generate Cobertura coverage report
run: reportgenerator -reports:**/coverage.cobertura.xml -targetdir:coverage -reporttypes:Cobertura

# - name: Find coverage report
# run: find . -name 'coverage.cobertura.xml'
- name: Find coverage report
id: find_coverage
run: |
COVERAGE_FILE=$(find . -name 'coverage.cobertura.xml')
echo "::set-output name=coverage_file::$COVERAGE_FILE"
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
with:
token: ${{ secrets.CODECOV_TOKEN }}
files: ${{ steps.find_coverage.outputs.coverage_file }}
flags: unittests
name: codecov-umbrella
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@

![Nuget](https://img.shields.io/nuget/dt/md5)
![Nuget](https://img.shields.io/nuget/v/md5)
[![codecov](https://codecov.io/gh/oalexandrefreire/MD5/graph/badge.svg?token=9TLI2KMZHX)](https://codecov.io/gh/oalexandrefreire/MD5)

# MD5

Expand Down

0 comments on commit 9777f9d

Please sign in to comment.