Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Jun 13, 2024. It is now read-only.

PR of pester quiet param fix and usebaicparsing for some pester tests. #29

Merged
devblackops merged 5 commits into PowerShell:master from larssb:master
Nov 2, 2017

Conversation

@larssb
Copy link

@larssb larssb commented Oct 30, 2017
edited by SteveL-MSFT
Loading

Description

Fixed the combination of using the OVF -TestFilePath parameter with invoke-pester -quiet or -show. The code, when using the -TestFilePath parameter did not take into consideration the version of Pester and therefore the warning about -Quiet.

While running the Pester tests. Several tests failed as I was using a user through "Runas" while in a Windows user session that is a non-admin user. The "Runas" user does not have IE configured in its profile and therefore the invoke-webrequest cmdlet fails without the -UseBasicParsing parameter. I added that to several tests to avoid this error. Shouldn't be an issue as it is very simple requests via that is tried with invoke-webrequest.

Related Issue

#28

Motivation and Context

To get rid of an unnecessary warning. That is already fixed for other parameters in OVF.

How Has This Been Tested?

  • Ran invoke-operationvalidation on actual tests on MacOS and thereby PowerShell core Beta v8.
  • Executed all the Pester tests provided in the repo.

Screenshots (if appropriate):

Types of changes

  • [ X] Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • [ X] My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • [X ] I have read the CONTRIBUTING document.
  • I have added tests to cover my changes. <-- I think the current tests already covers.
  • [ X] All new and existing tests passed.

This change is Reviewable

Lars and others added 2 commits October 26, 2017 20:53
- Avoid using extra call to get-module for performance reasons.
- Fix for quiet versus show Pester parameter when -TestFilePath parameter is used with OVF.
Added the -UseBasicParsing parameter in order to be compatible with running tests with a user that haven't had IE configured. Invoke-webrequest can then not parse the DOM as IE is used for this.
Copy link
Contributor

This look good to me @larssb. Thanks!

Copy link

msftclas commented Oct 31, 2017
edited
Loading

CLA assistant check
All CLA requirements met.

Copy link
Author

larssb commented Nov 1, 2017

Finally signed. I hope it will a breeze to merge it.

@devblackops have a good 1.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Reviewers

No reviews

Assignees

No one assigned

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /