Skip to content

Commit

Permalink
housekeeping: Update to use report generation (#406)
Browse files Browse the repository at this point in the history
  • Loading branch information
glennawatson authored Sep 15, 2020
1 parent 68d39ec commit 755250a
Show file tree
Hide file tree
Showing 9 changed files with 38 additions and 23 deletions.
28 changes: 26 additions & 2 deletions .github/workflows/ci-build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:

env:
configuration: Release
productNamespacePrefix: "DynamicData"

jobs:
build:
Expand Down Expand Up @@ -36,7 +37,7 @@ jobs:
with:
setAllVars: true

- name: Install Dependencies
- name: Restore NuGet Packages
run: dotnet restore
working-directory: src

Expand All @@ -45,4 +46,27 @@ jobs:

- name: Build
run: msbuild /t:build,pack /maxcpucount /p:NoPackageAnalysis=true /verbosity:minimal /p:Configuration=${{ env.configuration }}
working-directory: src
working-directory: src

- name: Install Report Generator
run: dotnet tool install --global dotnet-reportgenerator-globaltool

- name: Run Unit Tests
run: dotnet test --no-build /p:CollectCoverage=true /p:CoverletOutputFormat=cobertura /p:CoverletOutput="../../artifacts/coverage/coverage.xml" /p:Include="[${{ env.productNamespacePrefix}}*]*" /p:Exclude="[${{ env.productNamespacePrefix}}*Tests.*]*"
working-directory: src

- name: Generate Coverage Report
run: reportgenerator -reports:"coverage.*.xml" -targetdir:report-output
working-directory: artifacts/coverage

- name: Generate Coverage Artifacts
uses: actions/upload-artifact@master
with:
name: Coverage
path: artifacts/coverage/report-output

- name: Upload Code Coverage
uses: codecov/codecov-action@v1
with:
token: ${{ secrets.CODECOV_TOKEN }} # not required for public repos
directory: artifacts/coverage
File renamed without changes.
File renamed without changes.
Original file line number Diff line number Diff line change
@@ -1,11 +1,11 @@
<Project Sdk="MSBuild.Sdk.Extras">
<PropertyGroup>
<TargetFramework>netcoreapp2.2</TargetFramework>
<TargetFramework>netcoreapp3.1</TargetFramework>
<NoWarn>$(NoWarn);CS0618</NoWarn>
</PropertyGroup>

<ItemGroup>
<ProjectReference Include="..\DynamicData\DynamicData.csproj" />
<ProjectReference Include="..\..\src\DynamicData\DynamicData.csproj" />
</ItemGroup>

<ItemGroup>
Expand Down
File renamed without changes.
6 changes: 5 additions & 1 deletion src/DynamicData.Tests/DynamicData.Tests.csproj
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<Project Sdk="MSBuild.Sdk.Extras">
<PropertyGroup>
<TargetFrameworks>netcoreapp2.2;net462</TargetFrameworks>
<TargetFrameworks>netcoreapp3.1;net462</TargetFrameworks>
<NoWarn>$(NoWarn);CS0618;CA1801</NoWarn>
</PropertyGroup>

Expand All @@ -19,5 +19,9 @@
<PackageReference Include="xunit.runner.visualstudio" Version="2.4.3" />
<PackageReference Include="FluentAssertions" Version="5.10.3" />
<PackageReference Include="Microsoft.Reactive.Testing" Version="4.4.1" />
<PackageReference Include="coverlet.msbuild" Version="2.9.0">
<PrivateAssets>all</PrivateAssets>
<IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets>
</PackageReference>
</ItemGroup>
</Project>
23 changes: 5 additions & 18 deletions src/DynamicData.sln
Original file line number Diff line number Diff line change
Expand Up @@ -20,10 +20,13 @@ Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = ".other", ".other", "{DFCC45
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DynamicData.Tests", "DynamicData.Tests\DynamicData.Tests.csproj", "{1D53F0EE-F579-4398-82E5-ECAB2AA70BF1}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DynamicData.Profile", "DynamicData.Profile\DynamicData.Profile.csproj", "{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "DynamicData.Benchmarks", "DynamicData.Benchmarks\DynamicData.Benchmarks.csproj", "{42566F48-05FC-483E-8B2F-D0EA4F28E870}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Non Production", "Non Production", "{C2F87459-1CA6-4675-AF18-C4D0A0502F4D}"
ProjectSection(SolutionItems) = preProject
..\NonProduction\DynamicData.Profile\DynamicData.Profile.csproj = ..\NonProduction\DynamicData.Profile\DynamicData.Profile.csproj
EndProjectSection
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Expand Down Expand Up @@ -64,22 +67,6 @@ Global
{1D53F0EE-F579-4398-82E5-ECAB2AA70BF1}.Release|x64.Build.0 = Release|Any CPU
{1D53F0EE-F579-4398-82E5-ECAB2AA70BF1}.Release|x86.ActiveCfg = Release|Any CPU
{1D53F0EE-F579-4398-82E5-ECAB2AA70BF1}.Release|x86.Build.0 = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|Any CPU.Build.0 = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|Mixed Platforms.Build.0 = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|x64.ActiveCfg = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|x64.Build.0 = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|x86.ActiveCfg = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Debug|x86.Build.0 = Debug|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|Any CPU.ActiveCfg = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|Any CPU.Build.0 = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|Mixed Platforms.ActiveCfg = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|Mixed Platforms.Build.0 = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|x64.ActiveCfg = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|x64.Build.0 = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|x86.ActiveCfg = Release|Any CPU
{7A1B3B5B-50A0-491F-BC2F-513299DEE82D}.Release|x86.Build.0 = Release|Any CPU
{42566F48-05FC-483E-8B2F-D0EA4F28E870}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{42566F48-05FC-483E-8B2F-D0EA4F28E870}.Debug|Any CPU.Build.0 = Debug|Any CPU
{42566F48-05FC-483E-8B2F-D0EA4F28E870}.Debug|Mixed Platforms.ActiveCfg = Debug|Any CPU
Expand Down

0 comments on commit 755250a

Please sign in to comment.