mirror of
https://github.com/NanmiCoder/cc-haha
synced 2026-07-19 13:33:35 +08:00
fix(desktop): accept missing shared install paths
This commit is contained in:
parent
d7de7d47c9
commit
5dcf9b80d4
@ -293,7 +293,7 @@ function Get-ExistingInstallDirs {
|
|||||||
}
|
}
|
||||||
|
|
||||||
function Get-PotentialInstallDirs {
|
function Get-PotentialInstallDirs {
|
||||||
param([string[]]$InstallDirs)
|
param([AllowEmptyString()][string[]]$InstallDirs)
|
||||||
|
|
||||||
$seen = New-Object 'System.Collections.Generic.HashSet[string]' ([StringComparer]::OrdinalIgnoreCase)
|
$seen = New-Object 'System.Collections.Generic.HashSet[string]' ([StringComparer]::OrdinalIgnoreCase)
|
||||||
$result = New-Object 'System.Collections.Generic.List[string]'
|
$result = New-Object 'System.Collections.Generic.List[string]'
|
||||||
@ -805,7 +805,7 @@ function Run-SelfTest {
|
|||||||
New-Item -ItemType Directory -Path $perUserExternalTarget -Force | Out-Null
|
New-Item -ItemType Directory -Path $perUserExternalTarget -Force | Out-Null
|
||||||
New-Item -ItemType Junction -Path $perUserAppPayload -Target $perUserExternalTarget | Out-Null
|
New-Item -ItemType Junction -Path $perUserAppPayload -Target $perUserExternalTarget | Out-Null
|
||||||
$perUserResult = Invoke-LegacyRecovery `
|
$perUserResult = Invoke-LegacyRecovery `
|
||||||
-InstallDirs @($perUserInstall) `
|
-InstallDirs @($perUserInstall) -SharedInstallDirs @('') `
|
||||||
-UserDataDir (Join-Path $testRoot 'per-user app data') `
|
-UserDataDir (Join-Path $testRoot 'per-user app data') `
|
||||||
-RecoveryRoot (Join-Path $testRoot 'per-user recovery') -ProcessName $ProcessName `
|
-RecoveryRoot (Join-Path $testRoot 'per-user recovery') -ProcessName $ProcessName `
|
||||||
-ActiveConfigDir '' -SkipProcessCheck
|
-ActiveConfigDir '' -SkipProcessCheck
|
||||||
|
|||||||
@ -518,6 +518,7 @@ describe('release desktop workflow', () => {
|
|||||||
expect(installerHook).toContain('Quit')
|
expect(installerHook).toContain('Quit')
|
||||||
expect(recoveryHelper).toContain('function Get-LegacyActiveSource')
|
expect(recoveryHelper).toContain('function Get-LegacyActiveSource')
|
||||||
expect(recoveryHelper).toContain('function Get-PotentialInstallDirs')
|
expect(recoveryHelper).toContain('function Get-PotentialInstallDirs')
|
||||||
|
expect(recoveryHelper).toContain('param([AllowEmptyString()][string[]]$InstallDirs)')
|
||||||
expect(recoveryHelper).toContain('function Assert-NoUndiscoveredLegacySources')
|
expect(recoveryHelper).toContain('function Assert-NoUndiscoveredLegacySources')
|
||||||
expect(recoveryHelper).toContain('function Assert-NoRunningApplication')
|
expect(recoveryHelper).toContain('function Assert-NoRunningApplication')
|
||||||
expect(recoveryHelper).toContain('function Get-TreeManifest')
|
expect(recoveryHelper).toContain('function Get-TreeManifest')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user