Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Test report #1225

Merged
merged 1 commit into from
Apr 9, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 7 additions & 2 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,21 @@ jobs:
- uses: actions/checkout@v4
- uses: actions/setup-dotnet@v4
- run: dotnet build /p:TreatWarningsAsErrors=true
- run: dotnet test --no-build /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura
- run: dotnet test --no-build --logger 'junit' /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura
- uses: test-summary/action@v2
if: always()
with:
paths: 'test/**/TestResults/**/*.xml'
- uses: danielpalme/ReportGenerator-GitHub-Action@5
if: always()
with:
reports: 'test/**/*cobertura.xml'
reporttypes: 'Cobertura'
targetdir: '${{ github.workspace }}'
- uses: clearlyip/code-coverage-report-action@v4
id: code_coverage_report_action
# dont run for dependabot
if: ${{ github.actor != 'dependabot[bot]'}}
if: always() && ${{ github.actor != 'dependabot[bot]'}}
with:
filename: 'Cobertura.xml'
overall_coverage_fail_threshold: 75
Expand Down
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,9 @@ obj/
# dot user settings
*.DotSettings.user

# test logs
**/TestResults/**/*.xml

# code coverage results
*.coverage
*.coveragexml
Expand Down
1 change: 1 addition & 0 deletions test/Directory.Build.props
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@
<PackageReference Include="Meziantou.Xunit.ParallelTestFramework" Version="2.1.0"/>
<PackageReference Include="Verify.XUnit" Version="23.4.0" />
<PackageReference Include="Verify.DiffPlex" Version="2.3.0" />
<PackageReference Include="JunitXml.TestLogger" Version="3.1.12" />
<PackageReference Include="NSubstitute" Version="5.1.0" />
<PackageReference Include="NSubstitute.Analyzers.CSharp" Version="1.0.17">
<PrivateAssets>all</PrivateAssets>
Expand Down