@@ -179,9 +179,9 @@ Task Test TestServer, TestE2E, TestConstrainedLanguageMode
179179
180180Task TestServer TestServerWinPS, TestServerPS72, TestServerPS73
181181
182- # NOTE: While these can run under `pwsh.exe` we only want them to run under
183- # `powershell.exe` so that the CI time isn't doubled.
184- Task TestServerWinPS - If ($PSVersionTable .PSEdition -eq " Desktop " ) Build, SetupHelpForTests, {
182+ Task TestE2E TestE2EPwsh , TestE2EWinPS
183+
184+ Task TestServerWinPS - If (-not $ script :IsNix ) Build, SetupHelpForTests, {
185185 Set-Location .\test\PowerShellEditorServices.Test\
186186 # TODO: See https://github.com/dotnet/sdk/issues/18353 for x64 test host
187187 # that is debuggable! If architecture is added, the assembly path gets an
@@ -190,25 +190,30 @@ Task TestServerWinPS -If ($PSVersionTable.PSEdition -eq "Desktop") Build, SetupH
190190 Invoke-BuildExec { & dotnet $script :dotnetTestArgs $script :NetRuntime.Desktop }
191191}
192192
193- Task TestServerPS72 - If ( $PSVersionTable .PSEdition -eq " Core " ) Build, SetupHelpForTests, {
193+ Task TestServerPS72 Build, SetupHelpForTests, {
194194 Set-Location .\test\PowerShellEditorServices.Test\
195195 Invoke-BuildExec { & dotnet $script :dotnetTestArgs $script :NetRuntime.PS72 }
196196}
197197
198- Task TestServerPS73 - If ( $PSVersionTable .PSEdition -eq " Core " ) Build, SetupHelpForTests, {
198+ Task TestServerPS73 Build, SetupHelpForTests, {
199199 Set-Location .\test\PowerShellEditorServices.Test\
200200 Invoke-BuildExec { & dotnet $script :dotnetTestArgs $script :NetRuntime.PS73 }
201201}
202202
203- Task TestE2E Build, SetupHelpForTests, {
203+ Task TestE2EPwsh Build, SetupHelpForTests, {
204+ Set-Location .\test\PowerShellEditorServices.Test.E2E\
205+ $env: PWSH_EXE_NAME = " pwsh"
206+ Invoke-BuildExec { & dotnet $script :dotnetTestArgs $script :NetRuntime.PS73 }
207+ }
208+
209+ Task TestE2EWinPS - If (-not $script :IsNix ) Build, SetupHelpForTests, {
204210 Set-Location .\test\PowerShellEditorServices.Test.E2E\
205- $env: PWSH_EXE_NAME = if ( $IsCoreCLR ) { " pwsh " } else { " powershell" }
211+ $env: PWSH_EXE_NAME = " powershell"
206212 Invoke-BuildExec { & dotnet $script :dotnetTestArgs $script :NetRuntime.PS73 }
207213}
208214
209215Task TestConstrainedLanguageMode - If (-not $script :IsNix ) Build, SetupHelpForTests, {
210216 Set-Location .\test\PowerShellEditorServices.Test.E2E\
211- $env: PWSH_EXE_NAME = if ($IsCoreCLR ) { " pwsh" } else { " powershell" }
212217
213218 if (-not [Security.Principal.WindowsIdentity ]::GetCurrent().Owner.IsWellKnown(" BuiltInAdministratorsSid" )) {
214219 Write-Warning " Skipping Constrained Language Mode tests as they must be ran in an elevated process."
0 commit comments