Skip to content

Commit 35370b0

Browse files
author
Oyvind Timian Dokk Husveg
committed
Merge remote-tracking branch 'origin/main' into 119-auto-login-endpoint-variable-lifetime-of-token
2 parents 1e92f2c + c3634aa commit 35370b0

File tree

4 files changed

+38
-1
lines changed

4 files changed

+38
-1
lines changed

.github/workflows/testDotnetPostgres.yml

Lines changed: 22 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@ on:
55
branches: [ main ]
66
pull_request:
77
branches: [ main ]
8+
workflow_dispatch:
89

910
jobs:
1011
build-and-test:
@@ -80,4 +81,24 @@ jobs:
8081
--connection "$ConnectionStrings__LocalDatabase"
8182
8283
- name: Run tests
83-
run: dotnet test -c $CONFIGURATION
84+
run: dotnet test -c $CONFIGURATION --settings coverlet.runsettings
85+
86+
- name: Code Coverage Report
87+
uses: irongut/CodeCoverageSummary@v1.3.0
88+
with:
89+
filename: coverage/**/coverage.cobertura.xml
90+
badge: true
91+
fail_below_min: false
92+
format: markdown
93+
hide_branch_rate: false
94+
hide_complexity: true
95+
indicators: true
96+
output: both
97+
thresholds: '60 80'
98+
99+
- name: Add Coverage PR Comment
100+
uses: marocchino/sticky-pull-request-comment@v2
101+
if: github.event_name == 'pull_request'
102+
with:
103+
recreate: true
104+
path: code-coverage-results.md

.gitignore

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -421,6 +421,8 @@ autom4te.cache/
421421
*.tar.gz
422422
tarballs/
423423
test-results/
424+
coverage/
425+
coveragereport/
424426

425427
# Mac bundle stuff
426428
*.dmg

coverlet.runsettings

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<RunSettings>
2+
<DataCollectionRunSettings>
3+
<DataCollectors>
4+
<DataCollector friendlyName="XPlat Code Coverage">
5+
<Configuration>
6+
<CollectCoverage>true</CollectCoverage>
7+
<ExcludeByFile>**/*Migrations/*.cs</ExcludeByFile>
8+
</Configuration>
9+
</DataCollector>
10+
</DataCollectors>
11+
</DataCollectionRunSettings>
12+
</RunSettings>

exercise.sln

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,9 +12,11 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution
1212
IntegrationTestTemplate.txt = IntegrationTestTemplate.txt
1313
README.md = README.md
1414
UnitTestTemplate.txt = UnitTestTemplate.txt
15+
coverlet.runsettings = coverlet.runsettings
1516
EndProjectSection
1617
EndProject
1718
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "exercise.tests", "exercise.tests\exercise.tests.csproj", "{693E9261-FBC0-4112-95AF-2492AB6F1DE9}"
19+
EndProject
1820
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Diagrams_and_other_cool_stuff", "Diagrams_and_other_cool_stuff", "{02EA681E-C7D8-13C7-8484-4AC65E1B71E8}"
1921
ProjectSection(SolutionItems) = preProject
2022
..\..\..\..\Downloads\teamdevsim_v2.drawio = ..\..\..\..\Downloads\teamdevsim_v2.drawio

0 commit comments

Comments
 (0)