Skip to content

Update codecov/codecov-action to v4. #189

Update codecov/codecov-action to v4.

Update codecov/codecov-action to v4. #189

name: Components Tests on Windows
on:
push:
branches:
- main
jobs:
component-tests-on-windows:
runs-on: windows-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: '3.12'
cache: 'pip' # caching pip dependencies
- name: Install dependencies
run: pip install -r ./Scripts/etc/requirements.txt
- name: Apply pester tests
shell: pwsh
run: |
$PSVersionTable
"ErrorActionPreference: $ErrorActionPreference"
./Scripts/install.ps1
. ./Tests/Helpers/Register.Components.ps1
$config = New-PesterConfiguration
$config.Run.PassThru = $true
$config.Run.Path = './Tests/Components/'
$config.CodeCoverage.Path = "./Module/Private"
$config.CodeCoverage.OutputPath = 'coverage-private.xml'
$config.CodeCoverage.Enabled = $true
$config.Output.Verbosity = "Detailed"
Invoke-Pester -Configuration $config
$config = New-PesterConfiguration
$config.Run.PassThru = $true
$config.Run.Path = './Tests/APIs/'
$config.CodeCoverage.Path = "./Module/Public"
$config.CodeCoverage.OutputPath = 'coverage-public.xml'
$config.CodeCoverage.Enabled = $true
$config.Output.Verbosity = "Detailed"
Invoke-Pester -Configuration $config
- name: Upload coverage reports to Codecov
uses: codecov/codecov-action@v4
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}