Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/badgerati/pscoveralls
Cross-platform PowerShell module that allows you to publish Pester code coverage results to Coveralls.io
https://github.com/badgerati/pscoveralls
coverage coveralls cross-platform powershell tests
Last synced: 26 days ago
JSON representation
Cross-platform PowerShell module that allows you to publish Pester code coverage results to Coveralls.io
- Host: GitHub
- URL: https://github.com/badgerati/pscoveralls
- Owner: Badgerati
- License: mit
- Created: 2019-08-29T20:52:29.000Z (over 5 years ago)
- Default Branch: develop
- Last Pushed: 2019-08-30T22:40:15.000Z (over 5 years ago)
- Last Synced: 2024-11-15T11:41:56.257Z (3 months ago)
- Topics: coverage, coveralls, cross-platform, powershell, tests
- Language: PowerShell
- Size: 7.81 KB
- Stars: 2
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.txt
Awesome Lists containing this project
README
# PSCoveralls
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/Badgerati/PSCoveralls/master/LICENSE.txt)
This is a cross-platform PowerShell module that allows you to publish Pester code coverage results to Coveralls.io.
## Example
In order to use this module, you will need Pester.
1. The first step is to run your Pester tests, but using the `-CodeCoverage` switch:
```powershell
# you'll need the source files
$srcFiles = (Get-ChildItem "$($pwd)/src/*.ps1" -Recurse -Force).FullName# then, run your pester tests
$PesterReport = Invoke-Pester './tests' -CodeCoverage $srcFiles -PassThru
```2. Once you have your report, you can then make a report for Coveralls.io
```powershell
$CoverallsReport = New-CoverallsReport -Coverage $PesterReport.CodeCoverage -ServiceName 'appveyor' -BranchName master
```3. Finally, you can publish that report to Coveralls.io
```powershell
Publish-CoverallsReport -Report $CoverallsReport -ApiToken 'token'
```