Windows Vista Forums
Vista Forums Home Join Vista Forums Windows 7 Forum Vista Tutorials Tags
Welcome to Windows Vista Forums. Our forum is dedicated to helping you find solutions with any problems, errors or issues you are experiencing with Windows Vista. The Vista forum also covers news and updates and has an extensive Windows Vista tutorial section that covers a wide range of tips and tricks.

Go Back   Vista Forums > Misc Newsgroups > PowerShell

Vista - Re: Unittest powershell provider

Reply
 
Old 08-18-2008   #1 (permalink)
tojo2000


 
 

Re: Unittest powershell provider

On Aug 18, 1:11*pm, "newtops" <newt...@xxxxxx> wrote:
Quote:

> Hi,
>
> I'm working on a custom powershell provider. I am looking for a way to
> create unit tests to test this provider.
> I prefer to use the .Net unit test framework from within Visual Studio but
> don't see how to do this.
> I can of course call the .Net methods that form the provider directly from
> within a unit test but because the powershell output is written to the
> console and not as result of the unittest I don't know how the check if the
> test has succeeded or failed.
>
> Any suggestions?
>
> Thanks!
I've never used the .NET unit test framework. What is the output?

My System SpecsSystem Spec
Old 08-18-2008   #2 (permalink)
Oisin (x0n) Grehan [MVP]


 
 

Re: Unittest powershell provider

On Aug 18, 4:11*pm, "newtops" <newt...@xxxxxx> wrote:
Quote:

> Hi,
>
> I'm working on a custom powershell provider. I am looking for a way to
> create unit tests to test this provider.
> I prefer to use the .Net unit test framework from within Visual Studio but
> don't see how to do this.
> I can of course call the .Net methods that form the provider directly from
> within a unit test but because the powershell output is written to the
> console and not as result of the unittest I don't know how the check if the
> test has succeeded or failed.
>
> Any suggestions?
>
> Thanks!
Have a look at some of our unit tests in the powershell community
extensions. admittedly, we don't use many tests at all (probably a bad
thing) but since this is a part time endeavour for us, we hope it's
forgiveable ;-)

http://www.codeplex.com/PowerShellCX...ngeSetId=35629

- Oisin

PowerShell MVP
http://www.nivot.org/
My System SpecsSystem Spec
Reply

Thread Tools


Similar Threads
Thread Forum
Tab completion\expansion in Custom Powershell Provider PowerShell
How does one write "help" for a PowerShell provider? PowerShell
PowerShell OneNote Provider PowerShell
Powershell use of SNMP WMI Provider PowerShell
Info: Powershell provider for Visual Source safe. Anyone have one? PowerShell


Vista Forums is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media Ltd

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46