Skip to content

Commit c702047

Browse files
Fix module version
1 parent 688b41f commit c702047

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

test/SavePSResourceTests/SavePSResourceV2.Tests.ps1

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ Describe 'Test HTTP Save-PSResource for V2 Server Protocol' -tags 'CI' {
1313
$testScriptName = "test_script"
1414
$testModuleName2 = "testmodule99"
1515
$PackageManagement = "PackageManagement"
16+
$testModuleNameWithLicense = "ModuleRequireLicenseAcceptance"
1617
Get-NewPSResourceRepositoryFile
1718

1819
$SaveDir = Join-Path $TestDrive 'SavedResources'
@@ -203,9 +204,9 @@ Describe 'Test HTTP Save-PSResource for V2 Server Protocol' -tags 'CI' {
203204

204205
# Save resource that requires license
205206
It "Save resource that requires accept license with -AcceptLicense flag" {
206-
$pkg = Save-PSResource -Repository $PSGalleryName -TrustRepository -Path $SaveDir -Name $testModuleName2 -AcceptLicense -PassThru
207-
$pkg = Get-InstalledPSResource -Path $SaveDir -Name $testModuleName2
208-
$pkg.Name | Should -Be $testModuleName2
209-
$pkg.Version | Should -Be "0.0.1.0"
207+
$pkg = Save-PSResource -Repository $PSGalleryName -TrustRepository -Path $SaveDir -Name $testModuleNameWithLicense -AcceptLicense -PassThru
208+
$pkg = Get-InstalledPSResource -Path $SaveDir -Name $testModuleNameWithLicense
209+
$pkg.Name | Should -Be $testModuleNameWithLicense
210+
$pkg.Version | Should -Be "2.0.0.0"
210211
}
211212
}

0 commit comments

Comments
 (0)