Skip to content

Commit 8eb60d4

Browse files
docs: reset Test-Module workflow, rewrite README to imperative voice
1 parent a31c626 commit 8eb60d4

File tree

2 files changed

+11
-15
lines changed

2 files changed

+11
-15
lines changed

.github/workflows/Test-Module.yml

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,6 @@ jobs:
7272
Version: ${{ fromJson(inputs.Settings).Version }}
7373
WorkingDirectory: ${{ fromJson(inputs.Settings).WorkingDirectory }}
7474
Settings: Module
75-
CodeCoverage_Enabled: true
76-
CodeCoverage_OutputFormat: JaCoCo
77-
CodeCoverage_CoveragePercentTarget: 0
7875

7976
Lint-Module:
8077
name: Lint-Module (${{ matrix.OSName }})

README.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -163,15 +163,14 @@ The [PSModule - SourceCode tests](./scripts/tests/SourceCode/PSModule/PSModule.T
163163
- [PSModule framework settings for style and standards for modules](https://github.com/PSModule/Test-PSModule?tab=readme-ov-file#module-tests)
164164
- [PSScriptAnalyzer rules](https://github.com/PSModule/Invoke-ScriptAnalyzer)
165165
- This produces a JSON-based report that is used by [Get-PesterTestResults](#get-test-results) evaluate the results of the tests.
166-
- **Code coverage for framework-generated code**: This step also collects code coverage. During the
167-
[build step](#build-module), [Build-PSModule](https://github.com/PSModule/Build-PSModule) injects boilerplate code
168-
into the compiled `.psm1` file — including the `$IsWindows` compatibility shim, type accelerator registration for
169-
public classes and enums, and the `OnRemove` cleanup hook. Because this code is generated by the framework, module
170-
authors have no way to test it themselves. The framework tests in
171-
[Test-PSModule](https://github.com/PSModule/Test-PSModule) exercise these code paths so they are covered.
172-
The coverage artifacts from this step are aggregated with coverage from
173-
[Test-ModuleLocal](#test-module) in the [Get code coverage](#get-code-coverage) step, ensuring that
174-
framework-generated lines no longer appear as uncovered in the module author's coverage report.
166+
- **Code coverage for framework-generated code**: This step collects code coverage for framework-generated
167+
boilerplate. During the [build step](#build-module), [Build-PSModule](https://github.com/PSModule/Build-PSModule)
168+
injects boilerplate code into the compiled `.psm1` file — including the `$IsWindows` compatibility shim, type
169+
accelerator registration for public classes and enums, and the `OnRemove` cleanup hook. The framework tests in
170+
[Test-PSModule](https://github.com/PSModule/Test-PSModule) exercise these code paths and produce coverage artifacts
171+
that are aggregated with coverage from [Test-ModuleLocal](#test-module) in the
172+
[Get code coverage](#get-code-coverage) step. This keeps framework-generated lines from counting against the module
173+
author's coverage report.
175174

176175
### Test module
177176

@@ -308,9 +307,9 @@ The [PSModule - Module tests](./scripts/tests/Module/PSModule/PSModule.Tests.ps1
308307

309308
[workflow](./.github/workflows/Get-CodeCoverage.yml)
310309
- Gathers the code coverage from the previous steps and creates a summary of the results.
311-
- Coverage is aggregated from both the [Framework test](#framework-test) step (which covers framework-generated
312-
boilerplate) and the [Test module](#test-module) step (which covers module author code). A command that is executed
313-
in either step counts as covered. This ensures module authors are not penalized for lines they did not write.
310+
- Aggregates coverage from the [Framework test](#framework-test) step (framework-generated boilerplate) and the
311+
[Test module](#test-module) step (module author code). A command executed in either step counts as covered, so
312+
framework-generated lines do not count against the module author's coverage target.
314313
- If the code coverage is below the target, the workflow will fail here.
315314

316315
### Publish module

0 commit comments

Comments
 (0)