The Wiert Corner – irregular stream of stuff

Jeroen W. Pluimers on .NET, C#, Delphi, databases, and personal interests

  • My badges

  • Twitter Updates

  • My Flickr Stream

  • Pages

  • All categories

  • Enter your email address to subscribe to this blog and receive notifications of new posts by email.

    Join 4,259 other subscribers

Archive for the ‘MSTest’ Category

nunit – How can I view .NET trace logs in TeamCity? – Stack Overflow

Posted by jpluimers on 2016/02/23

This indeed works very well:

All console output is shown in the build log.

So when you need more context on tests that succeed, you can just output them on the Console.

A practical use: testing the sending of SMS messages over HTTPS where the intermediate proxy can change and was giving different effects.

Logging the actual proxy used correlated some run-time findings. Based on that we could write better tests.

–jeroen

via: nunit – How can I view .NET trace logs in TeamCity? – Stack Overflow.

Posted in .NET, Agile, C#, Continuous Integration, Development, MSTest, Software Development, TeamCity, Testing.NET, Unit Testing, VSTest | Leave a Comment »

On why there is no Assert.AreEqual(T t1, T t2) where T: IEquatable – via Stack Overflow

Posted by jpluimers on 2015/09/08

On why there is no

Assert.AreEqual<T>(T t1, T t2) where T: IEquatable<T>

Interesting. And I need to give some thought because when calling Assert.AreEqual<T1, T2>(T1 object1, T2 object2) where T1 does not equal T2 will map to Assert.AreEqual(object, object) without compile time warning.

Assert.AreEqual(object, object) ultimately calls Assert.AreEqual<T>(T, T, String, Object[]) which calls Object.Equals(object, object) failing only at run-time.

This has bitten me too many times.

I wonder what NUnit provides here; will look into that later.

–jeroen

via: c# – Microsoft.VisualStudio.TestTools.UnitTesting.Assert generic method overloads behavior – Stack Overflow.

Posted in .NET, Agile, C#, C# 3.0, C# 4.0, C# 5.0, C# 6 (Roslyn), Development, MSTest, NUnit, Software Development, Testing.NET, Unit Testing, VSTest | Leave a Comment »