Skip to content

Commit

Permalink
use artifact files for exe tests
Browse files Browse the repository at this point in the history
  • Loading branch information
jworkmanjc committed Jan 30, 2025
1 parent 7fd1f56 commit a215a61
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 2 deletions.
2 changes: 2 additions & 0 deletions .github/workflows/admu-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -149,6 +149,8 @@ jobs:
uses: actions/download-artifact@v4
with:
name: jumpcloud-admu-build
- name: Display structure of downloaded files
run: ls -R
- uses: actions/cache@v4
with:
path: 'C:\Users\runneradmin\Documents\PowerShell\Modules\'
Expand Down
11 changes: 9 additions & 2 deletions jumpcloud-ADMU/Powershell/Tests/Build.Tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -99,8 +99,15 @@ Describe "Module Validation Tests" {
$masterForm = (Invoke-WebRequest https://raw.githubusercontent.com/TheJumpCloud/jumpcloud-ADMU/master/jumpcloud-ADMU/Powershell/Private/DisplayForms/Form.ps1 -useBasicParsing).ToString()
$masterVersion = Select-String -InputObject:($masterForm) -Pattern:($VersionRegex)
$masterFormVersion = [version]$masterVersion.Matches.value
$gui_exeVersion = [version](Get-Item ("$PSScriptRoot\..\..\exe\gui_jcadmu.exe")).VersionInfo.FileVersion
$wup_exeVersion = [version](Get-Item ("$PSScriptRoot\..\..\exe\uwp_jcadmu.exe")).VersionInfo.FileVersion
if ($CI) {
$gui_exePathFromArtifact = "$GITHUB_WORKSPACE\jumpcloud-admu-build\Exe\gui_jcadmu.exe"
$uwp_exePathFromArtifact = "$GITHUB_WORKSPACE\jumpcloud-admu-build\Exe\uwp_jcadmu.exe"
} else {
$gui_exePathFromArtifact = "$PSScriptRoot\..\..\exe\gui_jcadmu.exe"
$uwp_exePathFromArtifact = "$PSScriptRoot\..\..\exe\uwp_jcadmu.exe"
}
$gui_exeVersion = [version](Get-Item ("$gui_exePathFromArtifact")).VersionInfo.FileVersion
$wup_exeVersion = [version](Get-Item ("$uwp_exePathFromArtifact")).VersionInfo.FileVersion
if ($env:ModuleVersionType -eq "manual") {
$gui_exeVersion | Should -be $psd1Version
$wup_exeVersion | Should -be $psd1Version
Expand Down

0 comments on commit a215a61

Please sign in to comment.