Saturday, 18 June 2011

New nUnit Test style; Assert.That

New (actually quite old by now) NUnit test style reads far more fluently than the old one. It is more verbose by I greatly prefer it.


[TestFixture]
public class HelloWorld {
[Test]
public void Should_say_hello() {
Assert.That("Hello World",
Is.EqualTo( new Welcomer().SayHello() ));
}
}

No comments: