mirror of
https://github.com/NanmiCoder/cc-haha
synced 2026-07-21 14:03:35 +08:00
fix(release): remove environment-dependent alias fixture
This commit is contained in:
parent
f8cccb096f
commit
100a2b25b8
@ -790,20 +790,6 @@ function Run-SelfTest {
|
|||||||
}
|
}
|
||||||
Assert-SelfTest -Condition $possibleShortAliasFailed -Message 'possible 8.3 alias did not fail closed'
|
Assert-SelfTest -Condition $possibleShortAliasFailed -Message 'possible 8.3 alias did not fail closed'
|
||||||
|
|
||||||
$existingShortAlias = Join-Path ([IO.Path]::GetPathRoot($testRoot)) 'PROGRA~1'
|
|
||||||
if ([IO.Directory]::Exists($existingShortAlias) -or [IO.File]::Exists($existingShortAlias)) {
|
|
||||||
$existingShortAliasFailed = $false
|
|
||||||
try {
|
|
||||||
Resolve-CanonicalPath -Path $existingShortAlias | Out-Null
|
|
||||||
} catch {
|
|
||||||
$existingShortAliasFailed = (
|
|
||||||
$_.Exception.Message.Contains('Alternate path alias') -or
|
|
||||||
$_.Exception.Message.Contains('8.3 path alias')
|
|
||||||
)
|
|
||||||
}
|
|
||||||
Assert-SelfTest -Condition $existingShortAliasFailed -Message 'existing 8.3 alias did not fail closed'
|
|
||||||
}
|
|
||||||
|
|
||||||
$legalTildePath = Join-Path $testRoot 'project~notes'
|
$legalTildePath = Join-Path $testRoot 'project~notes'
|
||||||
New-Item -ItemType Directory -Path $legalTildePath | Out-Null
|
New-Item -ItemType Directory -Path $legalTildePath | Out-Null
|
||||||
$resolvedLegalTildePath = Resolve-CanonicalPath -Path $legalTildePath
|
$resolvedLegalTildePath = Resolve-CanonicalPath -Path $legalTildePath
|
||||||
|
|||||||
@ -23,8 +23,8 @@ describe('Windows installer recovery prerequisites', () => {
|
|||||||
expect(recoveryHelper).toContain("([string]$_.Name).Equals($segment")
|
expect(recoveryHelper).toContain("([string]$_.Name).Equals($segment")
|
||||||
expect(recoveryHelper).toContain("Join-Path $testRoot 'project~notes'")
|
expect(recoveryHelper).toContain("Join-Path $testRoot 'project~notes'")
|
||||||
expect(recoveryHelper).toContain("Join-Path $testRoot 'MISSIN~1'")
|
expect(recoveryHelper).toContain("Join-Path $testRoot 'MISSIN~1'")
|
||||||
|
expect(recoveryHelper).not.toContain("'PROGRA~1'")
|
||||||
expect(recoveryHelper).toContain('possible 8.3 alias did not fail closed')
|
expect(recoveryHelper).toContain('possible 8.3 alias did not fail closed')
|
||||||
expect(recoveryHelper).toContain('existing 8.3 alias did not fail closed')
|
|
||||||
expect(recoveryHelper).toContain('legal long directory name containing a tilde')
|
expect(recoveryHelper).toContain('legal long directory name containing a tilde')
|
||||||
expect(recoveryHelper).toContain('extended volume alias did not fail closed')
|
expect(recoveryHelper).toContain('extended volume alias did not fail closed')
|
||||||
expect(recoveryHelper).toContain('SUBST alias did not fail closed')
|
expect(recoveryHelper).toContain('SUBST alias did not fail closed')
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user