Functional Testing, BDD and domain-specific languages

I love Test Driven Development (TDD). If you look back through the posts on this blog that soon becomes apparent. I’m pretty comfortable with using TDD techniques at all levels of a solution, from the tiniest code snippet to multiply-redundant collaborating systems. Of course, the difficulty of actually coding the tests in a test-driven design …

Continue reading ‘Functional Testing, BDD and domain-specific languages’ »

Spike Driven Development

test-Driven development (TDD) is a very powerful and beneficial approach to developing software. I routinely recommend it as a solution to untested and hard-to maintain software. However, every rule has its exceptions and there are occasions when a pure TDD approach is not very helpful. Mark Needham wrote a recent blog post on the subject …

Continue reading ‘Spike Driven Development’ »

A good aspect of the Oracle/Sun purchase

There has been a lot of speculation and worry about Oracle’s acquisition of Sun, so it’s nice to see some positive aspects. Here’s one about an improved attitude to automated testing. One of the results of the Oracle purchase of Sun has been an increased focus on testing — not that we didn’t test GlassFish …

Continue reading ‘A good aspect of the Oracle/Sun purchase’ »

What Developers Need to Know About Agile

Stephan Schmidt writes Agile is mostly driven driven by managment and consultants, seldom bottom up by developers. I found this very odd, and completely contrary to my own experience. From the perspective of someone who first encountered agile approaches in the form of Extreme Programming the problem is almost always how to explain the obvious …

Continue reading ‘What Developers Need to Know About Agile’ »

Steve Freeman compares Test-Driven Development to rock climbing

I love this kind of analogy. Thinking and learning about one area by considering another is a very powerful technique for boosting overall understanding and wisdom. In this case, Steve Freeman has scraped off the climbing terminology from a snippet of an article and replaced it with jargon from software development. Thought-provoking. Tips on Test-Driven …

Continue reading ‘Steve Freeman compares Test-Driven Development to rock climbing’ »

Fun with very strict TDD

I use Test-Driven Development (TDD) every day, and find it very helpful. It can be hard to get to grips with, though. I was pleased to read that acceptance-testing pundit Gojko Adzic had fun with some very strict TDD rules. Gojko Adzic » Thought-provoking TDD exercise at the Software Craftsmanship conference. My approach to TDD …

Continue reading ‘Fun with very strict TDD’ »

Testing is Overrated

A conference presentation from RubyFringe, designed to be contentious. There are some good points, particularly about the way that different approaches to testing can complement each other, but I think he misses the point about TDD when he lumps it in with developer unit testing and ignores the design aspects of the technique. InfoQ: Testing …

Continue reading ‘Testing is Overrated’ »

Test-Driven Development of HTTP and REST interfaces with Mojasef

Test-Driven Development (TDD) of HTTP and REST interfaces can be tricky. This post contains some examples of how to do it using the open source Mojasef toolkit. I was prompted to write this post after recently finding and fixing an irritating bug using just this technique. First, let’s set the scene. In TDD the rules …

Continue reading ‘Test-Driven Development of HTTP and REST interfaces with Mojasef’ »

TDD: Does it make you slower?

I use Test-driven Development (TDD) all the time. Although my immediate work colleagues have “bought in” to the idea, I sometimes find my self explaining about it to other people in other situations. A common question is whether the extra effort of writing all those tests slows down the overall development process. Mark Needham has …

Continue reading ‘TDD: Does it make you slower?’ »

How does Architecture fit with TDD

It’s a common conundrum once a team embraces test-driven development (TDD). What becomes of the role of architect? Some suggestions include moving the role of the architect even higher than in a typical waterfall or “over the wall” process. Sarah Taraporewalla’s Technical Ramblings » How does Architecture fit with TDD My take on this is …

Continue reading ‘How does Architecture fit with TDD’ »

TDD and Test-Driven Refactoring

This is a neat observation. One equivalent to test-Driven Development (TDD) when working with an existing codebase might be “test-driven refactoring”. The idea seems to be that at any particular point in the lifecycle of a software system not all of the benefits of TDD are actually being used. So why not just do enough …

Continue reading ‘TDD and Test-Driven Refactoring’ »

Increasing Code Coverage May Be Harmful

I develop almost all my code these days using Test Driven Development (TDD). By taking this approach I never bother about unit test code coverage, but some developers seem very concerned by it. One thing that I have never considered doing is retroactively adding tests just to increase some code-coverage metric. Dan Manges has written …

Continue reading ‘Increasing Code Coverage May Be Harmful’ »

Small and Simple Web Applications – the Friki Way

A few years go I wrote a series of articles for The Java Ranch Journal entitled “Small and Simple Web Applications – the Friki Way”. The series showed an example of developing a very simple wiki (collaborative editable web site) in Java using Test-Driven Development (TDD) and a form of agile project management. From time …

Continue reading ‘Small and Simple Web Applications – the Friki Way’ »

mockito 1.5 and spying on objects

Mockito is a Java Mock objects framework which seems more usable than either of the main contenders (JMock and EasyMock). The project has just released a new version which now allows the attachment of a mock “overlay” to an existing object. This has been on my “evaluate” stack for months, but (as Harry Pynn pointed …

Continue reading ‘mockito 1.5 and spying on objects’ »