Archive for the tag 'unit testing'

Jan 16 2009

Setting up testdata with test data builders

Published by under Java

Doing TDD has become a way of life for me. One the one hand tests are the security net that lets me refactor my code, but is also a restricting force when it comes to changing code. Experience has showed that when I refactor, I also break a lot of tests that’s not relevant for [...]

4 responses so far

Dec 12 2008

Quicker JUnit Spring context tests in Maven

Published by under Java

This is probably fairly well known, but I couldn’t find any doc on it when I searched so I’ll put it up here.
First off: Don’t load your Spring Context in your tests unless you absolutely have to. Some integration tests should load it, but keep it to a minimum. Loading the context is expensive, especially [...]

3 responses so far

Mar 06 2008

GUTs and BUTs

Published by under Java

Alright, so it’s a cheap one, but I had to do it. Alistair Cockburn coined the term GUTs – Good Unit Tests in a blog entry. Having a term for it was a bit of an eye opener.
I do TDD, but it’s not always the way I do stuff so I’m not religious [...]

No responses yet