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