mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Correct casing for automatic variables (#11568)
* Remove BOM, insert newline at EOF * Correct case of $MyInvocation special variable * Correct case of $OFS special variable * Correct case of $NestedPromptLevel special variable * Correct case of $Matches special variable * Correct case of $LASTEXITCODE special variable * Correct case of $StackTrace special variable * Correct case of $args special variable * Correct case of $this special variable * Correct case of $input special variable * Correct case of $PSCmdlet special variable * Correct case of $error special variable * Correct case of $PSDefaultParameterValues special variable * Correct case of $PSScriptRoot special variable * Correct case of $PWD special variable * Correct case of $null special variable * Correct case of $true special variable * Correct case of $false special variable * Correct case of $PSModuleAutoLoadingPreference special variable * Correct case of $IsLinux special variable * Correct case of $IsMacOS special variable * Correct case of $IsWindows special variable * Correct case of $IsCoreCLR special variable * Correct case of $DebugPreference special variable * Correct case of $VerbosePreference special variable * Correct case of $InformationPreference special variable * Correct case of $ExecutionContext special variable * Correct case of $HOME special variable * Correct case of $Host special variable * Correct case of $PID special variable * Correct case of $PSCulture special variable * Correct case of $PSHOME special variable * Correct case of $PSUICulture special variable * Correct case of $PSVersionTable special variable * Fix false positives
This commit is contained in:
+2
-2
@@ -502,7 +502,7 @@ Describe "PSModulePath changes interacting with other PowerShell processes" -Tag
|
||||
Restore-ModulePath
|
||||
}
|
||||
|
||||
It "Allows Windows PowerShell subprocesses to call `$PSHome modules still" {
|
||||
It "Allows Windows PowerShell subprocesses to call `$PSHOME modules still" {
|
||||
$errors = powershell.exe -Command "Get-ChildItem" 2>&1 | Where-Object { $_ -is [System.Management.Automation.ErrorRecord] }
|
||||
$errors | Should -Be $null
|
||||
}
|
||||
@@ -516,7 +516,7 @@ Describe "PSModulePath changes interacting with other PowerShell processes" -Tag
|
||||
<# Remove Pending status and update test after issue #11575 is fixed #>
|
||||
It "Does not duplicate the System32 module path in subprocesses" -Pending:$true {
|
||||
$sys32ModPathCount = & $pwsh -C {
|
||||
& "$PSHOME/pwsh" -C '$null = $env:PSModulePath -match ([regex]::Escape((Join-Path $env:windir "System32" "WindowsPowerShell" "v1.0" "Modules"))); $matches.Count'
|
||||
& "$PSHOME/pwsh" -C '$null = $env:PSModulePath -match ([regex]::Escape((Join-Path $env:windir "System32" "WindowsPowerShell" "v1.0" "Modules"))); $Matches.Count'
|
||||
}
|
||||
|
||||
$sys32ModPathCount | Should -Be 1
|
||||
|
||||
Reference in New Issue
Block a user