diff --git a/desktop/build/recover-legacy-install-data.ps1 b/desktop/build/recover-legacy-install-data.ps1 index 766baa76..f314de4d 100644 --- a/desktop/build/recover-legacy-install-data.ps1 +++ b/desktop/build/recover-legacy-install-data.ps1 @@ -293,7 +293,7 @@ function Get-ExistingInstallDirs { } function Get-PotentialInstallDirs { - param([string[]]$InstallDirs) + param([AllowEmptyString()][string[]]$InstallDirs) $seen = New-Object 'System.Collections.Generic.HashSet[string]' ([StringComparer]::OrdinalIgnoreCase) $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 Junction -Path $perUserAppPayload -Target $perUserExternalTarget | Out-Null $perUserResult = Invoke-LegacyRecovery ` - -InstallDirs @($perUserInstall) ` + -InstallDirs @($perUserInstall) -SharedInstallDirs @('') ` -UserDataDir (Join-Path $testRoot 'per-user app data') ` -RecoveryRoot (Join-Path $testRoot 'per-user recovery') -ProcessName $ProcessName ` -ActiveConfigDir '' -SkipProcessCheck diff --git a/scripts/pr/release-workflow.test.ts b/scripts/pr/release-workflow.test.ts index fb6dd91a..dc7cbdc1 100644 --- a/scripts/pr/release-workflow.test.ts +++ b/scripts/pr/release-workflow.test.ts @@ -518,6 +518,7 @@ describe('release desktop workflow', () => { expect(installerHook).toContain('Quit') expect(recoveryHelper).toContain('function Get-LegacyActiveSource') expect(recoveryHelper).toContain('function Get-PotentialInstallDirs') + expect(recoveryHelper).toContain('param([AllowEmptyString()][string[]]$InstallDirs)') expect(recoveryHelper).toContain('function Assert-NoUndiscoveredLegacySources') expect(recoveryHelper).toContain('function Assert-NoRunningApplication') expect(recoveryHelper).toContain('function Get-TreeManifest')