Skip to content

Commit

Permalink
ci: fix test build task
Browse files Browse the repository at this point in the history
  • Loading branch information
lucasteles committed Jul 6, 2023
1 parent e8ea754 commit 19fef80
Show file tree
Hide file tree
Showing 3 changed files with 51 additions and 52 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ jobs:
run: dotnet nuke lint

- name: Tests
run: dotnet nuke test-coverage --configuration Release --skip build --no-logo
run: dotnet nuke test --configuration Release --skip build --no-logo

- name: Test Result
if: ${{ github.actor != 'dependabot[bot]' && (success() || failure()) }}
Expand Down
100 changes: 50 additions & 50 deletions .github/workflows/pull_request.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,63 +15,63 @@ jobs:
cancel-in-progress: true

steps:
- uses: actions/checkout@v2
with:
fetch-depth: 0
- uses: actions/checkout@v2
with:
fetch-depth: 0

- name: Setup .NET Core
uses: actions/setup-dotnet@v2
with:
global-json-file: global.json
- name: Setup .NET Core
uses: actions/setup-dotnet@v2
with:
global-json-file: global.json

- name: Tool Restore
run: dotnet tool restore
- name: Tool Restore
run: dotnet tool restore

- name: Build
run: dotnet nuke build
- name: Build
run: dotnet nuke build

- name: Lint
run: dotnet nuke lint
- name: Lint
run: dotnet nuke lint

- name: Tests
run: dotnet nuke test-coverage --configuration Release --skip build --no-logo
- name: Tests
run: dotnet nuke test --configuration Release --skip build --no-logo

- name: Test Result
if: ${{ github.actor != 'dependabot[bot]' && (success() || failure()) }}
uses: dorny/[email protected]
with:
name: Test Report
reporter: dotnet-trx
path: tests/**/test_result.xml
- name: Test Result
if: ${{ github.actor != 'dependabot[bot]' && (success() || failure()) }}
uses: dorny/[email protected]
with:
name: Test Report
reporter: dotnet-trx
path: tests/**/test_result.xml

- name: Generate Coverage Html Report
if: ${{ github.actor != 'dependabot[bot]' }}
run: dotnet nuke generate-report --no-logo
- name: Generate Coverage Html Report
if: ${{ github.actor != 'dependabot[bot]' }}
run: dotnet nuke generate-report --no-logo

- name: Coverage monitor
uses: slavcodev/coverage-monitor-action@v1
if: ${{ github.actor != 'dependabot[bot]' }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
coverage_path: TestReport/Clover.xml
comment_mode: update
threshold_alert: 50
threshold_warning: 80
comment_footer: false
- name: Coverage monitor
uses: slavcodev/coverage-monitor-action@v1
if: ${{ github.actor != 'dependabot[bot]' }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
coverage_path: TestReport/Clover.xml
comment_mode: update
threshold_alert: 50
threshold_warning: 80
comment_footer: false

- name: Create CheckRun for code Coverage
uses: LouisBrunner/[email protected]
if: ${{ github.actor != 'dependabot[bot]' }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
name: Coverage Report Summary
conclusion: ${{ job.status }}
output_text_description_file: TestReport/Summary.md
output: '{"summary":"Created by Report-Generator"}'
- name: Create CheckRun for code Coverage
uses: LouisBrunner/[email protected]
if: ${{ github.actor != 'dependabot[bot]' }}
with:
token: ${{ secrets.GITHUB_TOKEN }}
name: Coverage Report Summary
conclusion: ${{ job.status }}
output_text_description_file: TestReport/Summary.md
output: '{"summary":"Created by Report-Generator"}'

- name: Upload Report
uses: actions/upload-artifact@v3
if: ${{ github.actor != 'dependabot[bot]' }}
with:
name: test_report
path: ./TestReport
- name: Upload Report
uses: actions/upload-artifact@v3
if: ${{ github.actor != 'dependabot[bot]' }}
with:
name: test_report
path: ./TestReport
1 change: 0 additions & 1 deletion src/Resulteles/ResultStatic.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,5 +60,4 @@ public static async Task<Result<TOk, Exception>> TryAsync<TOk>(Func<Task<TOk>> f
return e;
}
}

}

0 comments on commit 19fef80

Please sign in to comment.