Fix for LazyNeedle in .NET 4.0

Also imporved wait test.