... Home Contact

Krzysztof Koźmic's blog

You're doing it wrong.


Show appreciation: My Amazon.com Wish List

Me@Twitter

    Currently reading

    Article Categories

    Archives

    Post Categories

    MyPersonal

    Syndication:

    February 2009 Entries

    Lesson learned

    It pays up to hold on to your new year resolutions. I won a ReSharper license at today’s meeting of KGD.NET

    Mommy, there be dragons in my code.

    Every developer, and every shop has a Acme.Commons, or Acme.Core library, where they keep useful helper classes and extensions used in almost every project. Ayende has his Rhino Commons that I’ve seen him blogging about a few times but I never quite got around to actually take a look at the code… …until today, and I’m shocked. In a mostly positive way. There are few good ideas there, that I would like to discuss. The first class I found astonishing was HackExpiredException. My first reaction looked something like this: Then I looked for some...

    Castle Dynamic Proxy tutorial part VI: handling non-virtual methods

    This is part VI of my ongoing tutorial on Castle Dynamic Proxy. If you are new to it, you probably want to read previous parts first: Introduction The what, why and how Selecting which methods to intercept Breaking hard dependencies InterceptorSelector, fine grained control over...

    Castle Dynamic Proxy tutorial part V: InterceptorSelector, fine grained control over proxying

    This is part V of my ongoing tutorial on Castle Dynamic Proxy. If you are new to it, you probably want to read previous parts first: Introduction The what, why and how Selecting which methods to intercept Breaking hard dependencies Our Freezable library is starting to work quite well. However, there are still few glitches we need...

    Krzysztof++

    Happy birthday to me. Photo by bethography - melting mama

    Unit tests – keep it simple (KISS)!

    I have a tendency to overcomplicate things sometimes. Unit tests, are one such piece of code, that you want to keep as simple and clean as possible, so that other developers can easily find out how your class-or-method-under-test is supposed to work. There’s a principle for that that says it very strongly – “Keep it simple, stupid.” Don’t make it flexible when it does not have to be (just … hard code it). For example, when I was working on IInterceptorSelector support for Castle DynamicProxy, I had to test proxies without target, where return value is set by an...