Updated NCheck, my test object comparision helper, to version 2.2 which extends ICheckerFactory to support Compare<T> - this allows us to override checkers on a per-test basis which I’ve found useful on some of my current projects.
Customizing the CheckerFactory The CheckerFactory has a number conventions which are used to automatically construct Checkers for each class; these conventions can be overridden by the developer if they don’t suit a particular scenario.
Just release V2 of NCheck, my test object comparision helper which tidies up a few things that simplify custom comparisions and excluding properties.
Reworked the ITypeCompareTargter/IPropertyCompareTargeter into a a more generic IConvention<Source, Target> Introduced custom comparers and use convention-based registration for them. Retired Exclude, you can now use Compare(x => x.PropertyName).Ignore, unifies the syntax compared to other options.
With unit testing one of the precepts is to check one thing in your test, but when you have objects this is difficult to express, since you want to check that the your business process has updated all of the expected properties (positive testing) and also that has not modified things that are not expected to have changed (negative testing).
This becomes even more problematic when you have an object graph, e.
A number of years ago Sebasiten Lorion wrote a very good CSV parser for .NET with the code and an accompanying article on Code Project - A Fast CSV Reader. I’d used this in a number of projects but recently I needed to make some changes to the code for my trading system project, and there wasn’t a public repository available; there’s a version on NuGet but it doesn’t point back to the source.
I was working on the design of a small site where we have public display of information in one format and a set of administrative screens that allow authorised users to create and edit the information.
“I know”, I thought, “this is a perfect case for MVC Areas” – and boy was I wrong! I should have realised that the problems had started when all the routing started playing up..