Skip to content

Commit

Permalink
Update dotnet.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
thepirat000 authored Dec 16, 2023
1 parent 1f6420f commit 1567357
Showing 1 changed file with 16 additions and 52 deletions.
68 changes: 16 additions & 52 deletions .github/workflows/dotnet.yml
Original file line number Diff line number Diff line change
Expand Up @@ -64,58 +64,22 @@ jobs:
- name: Dotnet Build Audit.NET.sln
run: dotnet build .\Audit.NET.sln --no-restore --configuration release

#- name: Test Audit.IntegrationTest (AzureDocDb)
# run: dotnet test .\test\Audit.IntegrationTest --no-build --configuration release --verbosity normal --filter="TestCategory=AzureDocDb"
# env:
# AUDIT_NET_AZUREDOCDBAUTHKEY: ${{ secrets.AUDIT_NET_AZUREDOCDBAUTHKEY }}
# AUDIT_NET_AZUREDOCDBURL: ${{ secrets.AUDIT_NET_AZUREDOCDBURL }}
# AUDIT_NET_AZURETABLECNNSTRING: ${{ secrets.AUDIT_NET_AZURETABLECNNSTRING }}
# AUDIT_NET_AZUREBLOBSERVICEURL: ${{ secrets.AUDIT_NET_AZUREBLOBSERVICEURL }}
# AUDIT_NET_AZUREBLOBACCOUNTNAME: ${{ secrets.AUDIT_NET_AZUREBLOBACCOUNTNAME }}
# AUDIT_NET_AZUREBLOBACCOUNTKEY: ${{ secrets.AUDIT_NET_AZUREBLOBACCOUNTKEY }}

#- name: Test Audit.IntegrationTest (AzureStorage)
# run: dotnet test .\test\Audit.IntegrationTest --no-build --configuration release --verbosity normal --filter="TestCategory=AzureBlob|TestCategory=AzureStorageBlobs|TestCategory=AzureTables"
# env:
# AUDIT_NET_AZUREDOCDBAUTHKEY: ${{ secrets.AUDIT_NET_AZUREDOCDBAUTHKEY }}
# AUDIT_NET_AZUREDOCDBURL: ${{ secrets.AUDIT_NET_AZUREDOCDBURL }}
# AUDIT_NET_AZURETABLECNNSTRING: ${{ secrets.AUDIT_NET_AZURETABLECNNSTRING }}
# AUDIT_NET_AZUREBLOBSERVICEURL: ${{ secrets.AUDIT_NET_AZUREBLOBSERVICEURL }}
# AUDIT_NET_AZUREBLOBACCOUNTNAME: ${{ secrets.AUDIT_NET_AZUREBLOBACCOUNTNAME }}
# AUDIT_NET_AZUREBLOBACCOUNTKEY: ${{ secrets.AUDIT_NET_AZUREBLOBACCOUNTKEY }}
# AUDIT_NET_AZUREBLOBCNNSTRING: ${{ secrets.AUDIT_NET_AZUREBLOBCNNSTRING }}

- name: Test Audit.EntityFramework.Core.UnitTest
run: dotnet test .\test\Audit.EntityFramework.Core.UnitTest --no-build --configuration release --verbosity normal

#- name: Test Audit.AzureStorageTables.UnitTest
# run: dotnet test .\test\Audit.AzureStorageTables.UnitTest --no-build --configuration release --verbosity normal
# env:
# AUDIT_NET_AZURETABLECNNSTRING: ${{ secrets.AUDIT_NET_AZURETABLECNNSTRING }}
- name: Install Required Tools
run: |
dotnet new tool-manifest
dotnet tool install dotnet-reportgenerator-globaltool
dotnet tool install dotnet-coverage
- name: Test Audit.EntityFramework.Full.UnitTest
run: dotnet test .\test\Audit.EntityFramework.Full.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.Mvc.UnitTest
run: dotnet test .\test\Audit.Mvc.UnitTest --no-build --configuration release --verbosity normal
- name: Run unit tests
run: |
dotnet coverage collect dotnet test -m:1 --output ${{ github.workspace }}/Tests/Coverage.cobertura.xml --output-format cobertura
- name: Test Audit.JsonAdapter.UnitTest
run: dotnet test .\test\Audit.JsonAdapter.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.WebApi.UnitTest
run: dotnet test .\test\Audit.WebApi.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.DynamicProxy.UnitTest
run: dotnet test .\test\Audit.DynamicProxy.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.Wcf.UnitTest
run: dotnet test .\test\Audit.Wcf.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.Wcf.Client.UnitTest
run: dotnet test .\test\Audit.Wcf.Client.UnitTest --no-build --configuration release --verbosity normal

- name: Test Audit.UnitTest
run: dotnet test .\test\Audit.UnitTest --no-build --configuration release --verbosity normal

- name: Generate Code Coverage Report
run: |
dotnet reportgenerator -reports:${{ github.workspace }}/Tests/Coverage.cobertura.xml -targetdir:"${{ github.workspace }}/Tests/coveragereport" -reporttypes:"MarkdownSummary;Html" "-assemblyfilters:-*UnitTest"

- name: Upload Code Coverage Report
uses: actions/upload-artifact@v2
with:
name: coveragereport
path: ${{ github.workspace }}/Tests/coveragereport

0 comments on commit 1567357

Please sign in to comment.