5

I am unable to to output log messages to console via the Common.Logging framework in MbUnit tests run by TestDriven. I am not sure if it has to do with the way Gallio is registered with TestDriven. I followed the steps on this post ( Register a Gallio zip installation with TestDriven.Net ) to register Gallio with TestDriven manually because I don't have admin rights to the machine.

The same logging mechanism worked in NUnit + TestDriven.

Community
  • 1
  • 1
Candy Chiu
  • 6,579
  • 9
  • 48
  • 69

2 Answers2

6

If you really want to write messages to the Output pane in Visual Studio when running TestDriven.NET you can use Gallio.Framework.DiagnosticLog:

DiagnosticLog.WriteLine("Test message");

However, the log messages won't be associated to the tests and will show up as a separate section of the Gallio report. So in most cases you're better off using the Gallio.Framework.TestLog or System.Console and clicking on the Test Report link to see the results as Graham mentioned.

Scott Lerch
  • 2,620
  • 1
  • 23
  • 34
  • I am aware of DiagnosticLog. It would be nice if Gallio can channel log messages to the Output pane just like NUnit. – Candy Chiu Mar 20 '12 at 13:16
0

Console output goes into the test report (the blue link at the end of the TD.NET run), rather than being displayed in the console. Is there anything in there?

grahamrhay
  • 2,046
  • 4
  • 19
  • 29