Updating ModulePath.Tests for fxdependent package#7772
Merged
adityapatwardhan merged 2 commits intoPowerShell:masterfrom Sep 17, 2018
Merged
Updating ModulePath.Tests for fxdependent package#7772adityapatwardhan merged 2 commits intoPowerShell:masterfrom
adityapatwardhan merged 2 commits intoPowerShell:masterfrom
Conversation
adityapatwardhan
requested changes
Sep 12, 2018
Member
There was a problem hiding this comment.
this can be
$skipNoPwsh = -not (Test-Path $powershell)
iSazonov
approved these changes
Sep 13, 2018
adityapatwardhan
approved these changes
Sep 17, 2018
Member
|
Using administrator privileges to merge as the spellings CI did not trigger. This PR does not have any markdown content. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR Summary
It turns out that some tests rely on having 'pwsh' executable for starting powershell.
This is not the case when framework dependent 'fxdependent' package is used (in which case PS is started by command like
dotnet /opt/microsoft/powershell/pwsh.dll.Specifically ModulePath.Tests are used in package validation before every PS release and failures in them block testing fxdependent package that we are adding.
The fix is to skip failing tests that rely on 'pwsh' executable in testing fxdependent package.
A better fix would be to add a generic test utility function that returns proper PS starting command based on environment where Pester runs. But since current failures are blocking package validation, we can add this utility function later (I'll open an test issue to track this).
PR Checklist
.h,.cpp,.cs,.ps1and.psm1files have the correct copyright headerWIP:to the beginning of the title and remove the prefix when the PR is ready.[feature]if the change is significant or affects feature tests