Skip to content

Commit

Permalink
fix source path for pester test
Browse files Browse the repository at this point in the history
  • Loading branch information
james-garriss committed Nov 15, 2024
1 parent d16c531 commit 06557f4
Show file tree
Hide file tree
Showing 4 changed files with 6 additions and 6 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/publish_private_package.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,13 @@ jobs:
}
$Config = New-PesterConfiguration -Hashtable $PesterConfig
Invoke-Pester -Configuration $Config
# This is a manual test that simply writes the version to the console.
- name: Print Scuba Version
- name: Initialize ScubaGear
run: |
Install-Module -Name ScubaGear -Repository $env:GalleryName -SkipPublisherCheck
# Source the function
. repo/utils/workflow/Initialize-ScubaGearForTesting.ps1
Initialize-ScubaGearForTesting
# This is a manual test that simply writes the version to the console.
Invoke-SCuBA -Version
Test-Path -Path "C:\Program Files\WindowsPowerShell\Modules\ScubaGear"
- name: Install Selenium
Expand Down
4 changes: 2 additions & 2 deletions Testing/workflow/Initialize-ScubaGearForTesting.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,9 @@ param()

BeforeDiscovery {
# Source the function
. $PSScriptRoot/../../utils/workflow/
. $PSScriptRoot/../../utils/workflow/Initialize-ScubaGearForTesting.ps1
# Initialize SG
Initialize-ScubaGearForTesting.ps1
Initialize-ScubaGearForTesting
}

# Use Write-Warning b/c other writes don't actually write
Expand Down
2 changes: 1 addition & 1 deletion utils/workflow/Initialize-ScubaGearForTesting.ps1
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
function Initialize-ScubaGearForTesting {
<#
.DESCRIPTION
Installs ScubaGear for testing
Initializes ScubaGear for testing
#>

Write-Output 'Initializing ScubaGear for testing...'
Expand Down
2 changes: 1 addition & 1 deletion utils/workflow/Install-SeleniumForTesting.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@ function Install-SeleniumForTesting {
Join-Path -Path $RepoRootPath -ChildPath 'Testing/Functional/SmokeTest/UpdateSelenium.ps1'
# Workaround for Selenium. Loading psm1 instead of psd1
Import-Module -Name (Get-Module -Name Selenium -ListAvailable).Path -Force
}
}

0 comments on commit 06557f4

Please sign in to comment.