Home / ASP.NET Weblogs

Latest Microsoft Blogs

Browse by Tags

Related Posts

  • Moq Sequences Revisited

    A while back I wrote about mocking successive calls to the same method which returns a sequence of objects. Read that post for more context. In that post, I had written up an implementation, but quickly was won over by a better extension method implementation from Fredrik Kalseth . public static class MoqExtensions { public static void ReturnsInOrder<T, TResult>( this ISetup<T, TResult> setup, params TResult[] results) where T : class { setup.Returns( new Queue<TResult>(results).Dequeue); } } As good as this extension method is, I was able to improve on it today during a coding session. I was writing some code where I needed the second call to the same method to throw an exception and realized this extension wouldn’t allow...


  • Research Supports The Effectiveness of TDD

    In a recent post , Frans Bouma laments the lack of computer science or reference to research papers by agile pundits in various mailing lists (I bet this really applies to nearly all mailing lists, not just the ones he mentions). What surprised me to no end was the total lack of any reference/debate about computer science research, papers etc. ... in the form of CS research. Almost all the debates focused on tools and their direct techniques, not the computer science behind them. In general asking ’Why’ wasn’t answered with: "research has shown that..." but with replies which were pointing at techniques, tools and patterns, not the reasoning behind these tools, techniques and patterns. As a fan of the scientific method, I understand...


Page 1 of 1 (2 items)

Archives