mirror of
https://github.com/actions/versions-package-tools.git
synced 2025-12-10 19:50:24 +00:00
Refactor Pester installation step in workflow
This commit is contained in:
8
.github/workflows/build-tool-packages.yml
vendored
8
.github/workflows/build-tool-packages.yml
vendored
@@ -160,8 +160,12 @@ jobs:
|
||||
Write-Host "to determine if ${{ inputs.tool-name }} version was consumed from cache or if it was downloaded"
|
||||
for ($i = 0; $i -lt 200; $i++) { Get-Random }
|
||||
|
||||
- name: Install Pester
|
||||
run: Install-Module Pester -Force -Scope CurrentUser -SkipPublisherCheck
|
||||
- name: Ensure Pester Installed
|
||||
run: |
|
||||
$module = Get-Module -ListAvailable -Name Pester
|
||||
if (-not $module -or ($module.Version -lt [Version]"5.0.0")) {
|
||||
Install-Module Pester -Force -Scope CurrentUser -SkipPublisherCheck
|
||||
}
|
||||
|
||||
- name: Run tests
|
||||
if: env.excludewinarm == 'true'
|
||||
|
||||
Reference in New Issue
Block a user