Output value

Hi,

I am running to pester test and generating a html page from the results, but i’d like to have the results display so more detail
For instance, 1 of the tests copies some files across the network, but rather than showing that the files failed to be copied in a specified time, i’d like fail message to show the actual time taken.

The HTML file output (ReportUnit) just shows File copy should beLessThan 1

Hope this makes sense?

Cheers

Yep. In that case, you’d have to build your tests around the time then. Something like:

it 'copies within X time' {
## start timer
## do the copy
## stop timer and collect results
$time | should belessthan 10
}

Thanks Adam, I understand what i need to do. Is it possible to create html output that shows the results over a period of time rather than just the results of the most recent test. Ideally i’d like to see the time it takes of the course of a day and present this in the HTML output.

I can run the File copy in a While Loop, but it’s only when i invoke-pester the output is generated in NUnitXml.

Any ideas?