Skip to content

Invalid Renaming in Project Level Workspace #144

Invalid Renaming in Project Level Workspace

Invalid Renaming in Project Level Workspace #144

name: Unit Test with .NET
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
permissions:
pull-requests: write
jobs:
build:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout Repository
uses: actions/checkout@v4
- name: Setup .NET tools
uses: actions/setup-dotnet@v4
with:
dotnet-version: "8.0.x"
- name: Restore NuGet dependencies
run: |
dotnet restore ./src/Plana.sln
- name: Build
run: |
dotnet build ./src/Plana.sln --no-restore --configuration=Release
- name: Test
run: |
dotnet test ./src/Plana.sln --no-restore --collect="XPlat Code Coverage" --settings coverlet.runsettings --results-directory=./coverage
- name: ReportGenerator
uses: danielpalme/ReportGenerator-GitHub-Action@5.2.1
if: always() && matrix.os == 'ubuntu-latest'
with:
reports: ./coverage/**/coverage.cobertura.xml
targetdir: ./coverage
reporttypes: Cobertura
sourcedirs: ./src
- name: Publish Coverage
uses: irongut/CodeCoverageSummary@v1.3.0
if: always() && matrix.os == 'ubuntu-latest'
with:
filename: coverage/Cobertura.xml
badge: true
fail_below_min: true
format: markdown
hide_branch_rate: false
hide_complexity: true
indicators: true
output: both
thresholds: "60 80"
- name: Add Coverage PR Comment
uses: marocchino/sticky-pull-request-comment@v2
if: always() && github.event_name == 'pull_request' && matrix.os == 'ubuntu-latest'
with:
recreate: true
path: code-coverage-results.md