Add tests for PowerShell classes inheriting from abstract .NET classes#6752
Merged
daxian-dbw merged 5 commits intoPowerShell:masterfrom Apr 30, 2018
Merged
Conversation
daxian-dbw
reviewed
Apr 27, 2018
| } | ||
|
|
||
| It 'can subclass .NET abstract class' { | ||
| class TestHost : System.Management.Automation.Host.PSHost |
Member
There was a problem hiding this comment.
Can we group related tests in a Context? That way we don't need to duplicate the TestHost declaration 3 times.
iSazonov
approved these changes
Apr 29, 2018
daxian-dbw
approved these changes
Apr 30, 2018
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
Add some tests to check for regressions against #1760 (which magically was fixed at some point).
In particular this tests for:
If there are other things we should be testing for, let me know and I will add them.
Also, if there are other easily available .NET abstract classes that we could inherit from to diversify testing (particularly with non-
voidabstract methods), I would like to substitute one of those for aPSHostsubclass. (I just couldn't find any good candidates after searching for a while).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