Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Specify an output message for successful test case

Tags:

nunit

Each Assert allow to define error message which will be printed out in case of assert failure but can I somehow provide a message which will be outputed in case of successful test run?

like image 530
sll Avatar asked Jul 01 '11 10:07

sll


2 Answers

I just use Console.WriteLine( "Your message here" ); which will be directed to the NUnit output so you can see Test passed messages

like image 79
Smectymnuus Avatar answered Oct 14 '22 14:10

Smectymnuus


You can use the Assert.Pass utility method.

like image 22
Peter Lillevold Avatar answered Oct 14 '22 15:10

Peter Lillevold