Skip to content

Commit ae6689f

Browse files
committed
Summarize the Pester results (no report)
1 parent 329c4d5 commit ae6689f

File tree

3 files changed

+13
-22
lines changed

3 files changed

+13
-22
lines changed

Diff for: .github/workflows/build.yml

+10-6
Original file line numberDiff line numberDiff line change
@@ -109,14 +109,18 @@ jobs:
109109
# include_paths: tests
110110
# exclude_paths: tests/powershell1,tests/powershell2
111111
# exclude_tags: skip_ci
112-
report_name: module_tests
112+
report_name: ${{ matrix.os }}_validation
113113
report_title: My Module Tests
114114
github_token: ${{ secrets.GITHUB_TOKEN }}
115115
tests_fail_step: true
116-
- name: dump test results
116+
skip_check_run: true # Our test results are too large
117+
- name: Summarize test results
117118
shell: pwsh
118119
run: | # PowerShell
119-
Write-Host 'Total Tests Executed...: ${{ steps.pester.outputs.total_count }}'
120-
Write-Host 'Total Tests PASSED.....: ${{ steps.pester.outputs.passed_count }}'
121-
Write-Host 'Total Tests FAILED.....: ${{ steps.pester.outputs.failed_count }}'
122-
120+
Write-ActionInfo 'Total Tests Executed...: ${{ steps.pester.outputs.total_count }}'
121+
Write-ActionInfo 'Total Tests Passed.....: ${{ steps.pester.outputs.passed_count }}'
122+
if (${{ steps.pester.outputs.failed_count }} -gt 0) {
123+
Set-ActionFailed 'Total Tests Failed.....: ${{ steps.pester.outputs.failed_count }}'
124+
} else {
125+
Write-ActionInfo 'Total Tests Failed.....: ${{ steps.pester.outputs.failed_count }}'
126+
}

Diff for: Install-RequiredModule.ps1

-15
This file was deleted.

Diff for: build.requires.psd1

+3-1
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,11 @@
1-
# https://github.com/marketplace/actions/modulefast
1+
# Run Install-ModuleFast to install the latest version of the required modules
2+
# https://github.com/JustinGrote/ModuleFast
23
@{
34
Configuration = ":[1.5.0, 2.0)"
45
Metadata = ":[1.5.1, 2.0)"
56
Pester = ":[5.0, 6.0)"
67
ModuleBuilder = ":[3.0.0, 4.0)"
78
PSScriptAnalyzer = ":[1.21.0, 2.0)"
89
InvokeBuild = ":[5.10.4, 6.0)"
10+
GitHubActions = ":[1.1.0, 2.0)"
911
}

0 commit comments

Comments
 (0)