Skip to main content

I can’t go to bed right now

Someone is wrong on the internet.

In the past few episodes of the stackoverflow podcast Joel Spolsky and Jeff Atwood already talked about SOLID principles and TDD saying they don’t really care for it, they both seem to have been successful without it. They also admitted neither of them had any real experience with this style of programming. This is why I find it really surprising Jeff even took the trouble of writing another blog post about this voicing his opinions about a set of principles he clearly has never practiced.

First of all I find this post very unprofessional. In the short ten years I’ve been programming I’ve seen lots of practices, rules, patterns, principles, styles and methodologies. Some of them are successful, some of them aren’t. Some of them work in some situations and some of them never work and I never get tired of hearing people talk about what worked for them, what didn’t work for them and why. This post isn’t about that. Jeff admitted to not having much experience trying these principles, he does seem to have a couple of issues with rules though.

Jeff also seems to completely miss the point on what principles actually are. He goes on a rant of why rules are bad but principles aren't rules. In fact I think they are almost the opposite of rules. Rules are what made the 2Life Crew change the lyrics of their hit song Me so horny without changing its meaning. Principles are what drives you to not let your little sister listen to it. Rules tell you what to do in any situations. Principles describe where you want to go leaving you to decide what the next step will be to get you just a little closer.

The case for or against SOLID and TDD seems familiar. It’s an old discussion of efficiency vs. effectiveness. Not doing TDD and not doing things SOLID lets me write loads of code really fast, its really efficient. But programming is not about writing code. This may surprise some people. Programming is design. It’s about thinking. It will surprise you how few lines of code an average programmer writes, so typing is not a bottleneck. There are other bottlenecks. Maintenance and readability. SOLID and TDD address these bottlenecks leading to well partitioned readable code. The dynamics of writing code change from frantic sprints and evenings of bug-hunting to a sustainable pace.


Popular posts from this blog

Using xUnit.Net with .Net 4.0

I’ve been using xUnit.Net for a while now. It’s just a tiny bit cleaner and slightly less abrasive than other .Net unit testing frameworks. Leaving out unnecessary stuff like [TestFixture] and shortening Assert.AreEqual to the equally clear but shorter Assert.Equal don’t seem like big improvements but when you type them several times a day tiny improvements start to add up. I also like the use of the [Fact] attribute instead of [Test]. It shifts the focus from testing to defining behavior. So how do we get all this goodness working with the Visual Studio 2010 beta?

Square One available on the Android market

This is just a short post to let you know that a first version of the Android app I’ve been working on for the last couple of weeks is available on the Android market. The app is called Square One and it’s a simple bassline synthesizer. It’s free so try it out and let me know what you think of it, but be prepared it’s still an early version. I hope to add more features in the next few months and maybe build something that can be used to create real music.The lower part of the screen contains the sequencer controls that can be used to program your own bass lines. On the left is a four by four grid of buttons where you can select a step in the sequence. On the right you can select the note to be played on that step. When you’re done you can press Start and the sequence starts playing. The knobs on the top can be used to control a couple of parameters from the synthesizer engine that creates the sound. You can control the cutoff frequency and resonance of the low-pass filter, attack and …

Building Android projects with Jenkins, Ant and Mercurial

I have recently set up a Jenkins build server for my Android projects hosted on Bitbucket. It’s not difficult but there are a couple pitfalls and the information on how to do this isn’t available from one single place so I decided to document the process and put up the information over here. Maybe other people will benefit from having a step-by-step guide too.