This handy tip might save you from being bitten by an odd edge case:
Assert.IsTrue(new object[]{}.All(x=> false));
This assertion will always pass on an empty set, no matter what the lambda expression.
I scratched my head and thought about it for a it, and agreed that I don’t see any better way the .NET team could have implemented this, from an API perspective.
Tuesday, 14 August 2012