Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Quiet mode #223

Closed
timparkinson opened this issue Nov 13, 2014 · 5 comments
Closed

Quiet mode #223

timparkinson opened this issue Nov 13, 2014 · 5 comments

Comments

@timparkinson
Copy link

It would be super nice if invoke-pester supported a quiet flag that turned off the write-host output.

My use case for this is running pester from within a c# app - the write-hosts break this, as there is no writeable host to write to.

@nohwnd
Copy link
Member

nohwnd commented Nov 13, 2014

Sounds like an easy change. I will add that.
Just out of curiosity could you tell me more about the C# app you use Pester in? What is the purpose of that application? Showing the results of the tests?

@nohwnd
Copy link
Member

nohwnd commented Nov 13, 2014

Implemented the change in the referenced branch. Could you test it please and let me know if it works for you?

@timparkinson
Copy link
Author

Yes, that works perfectly. Thanks for the super-speedy response.

The c# I'm calling pester from is just a little ASP.Net endpoint being called from a github enterprise webhook - just running tests against the powershell code I'm pushing into the repo.

@nohwnd nohwnd closed this as completed in 11e29de Nov 14, 2014
@nohwnd
Copy link
Member

nohwnd commented Nov 14, 2014

@timparkinson Merged in master, not sure when we will release new version.

Btw I assume the reason why host output fails in your tool is that you use the PowerShell object to run the powershell code, right? You could also use the PSHost and implement the PSHostUserInterface and PSHostRawUserInterface to make the host output work. But yeah, it is bit more work, it adds complexity, and is totally unnecessary now that Pester is patched. Just letting you know in case you did not know it's possible and you had the same problem in the future with another project (where they don't respond this fast :))

@timparkinson
Copy link
Author

Cheers for the tip - you're correct I'm just using a powershell object.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants