Created
May 2, 2011 20:08
-
-
Save egomesbrandao/952260 to your computer and use it in GitHub Desktop.
Script Powershell para rodar os testes do MbUnit usando Gallio gerando e abrindo os relatórios em HTML
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
| if ( (Get-PSSnapin -Name Gallio -ErrorAction SilentlyContinue) -eq $null ) | |
| { | |
| Add-PsSnapin Gallio | |
| } | |
| $result = Run-Gallio "c:\[CAMINHO]\Test.dll" -ReportDirectory "c:[CAMINHO]\TestReports" -ReportTypes "Html" -ShowReports -Filter Type:@args[0] | |
| if ($result.Statistics.FailedCount -gt 0) | |
| { | |
| Write-Warning "Some unit tests have failed." | |
| } |
Author
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Fiz uma pequena revisão, acrescente o parâmetro -Filter e estou selecionando o teste a ser executado pelo Type, exemplo no command, o argumento "XYZTest" é a classe do teste unitário que eu quero executar:
powershell -file Script.ps1 XYZTest