NUnit and the constraint based model

At the Elevate presentation yesterday I learned a lot about C#3/4 by Magnus Lidbom.

But as a side-effect I also picked up a nifty syntax for NUnit assertions. It’s called Constraint-based Assertion Model and has been around since NUnit 2.4. Which shows that I am a slow adopter… Sad.

OK – what’s the deal with it? It gives you a almost fluent interface to assertions. Here is an example on how to do a simple assertion in the old style:

And here is the same assertion in the Constraint-based version:

Now read it out loud; Assert… That … i … is equal to 10. Nice, isn’t it? I like that a lot.

Read More

Inbox zero

First, admit that the title alone is very tempting… You want it, you need it… but how to get it?

How do you manage the steady flow of mail and requests during a day? How do you stay afloat? That’s what you can learn from picking up on the inbox zero concept.

I first learned about this concept at a presentation by Scott Hanselmann at ÖreDev. You can see this presentation here. Mr Hanselmann has put out some other advices that are well worth reading as well.

I then realized that the concept is older than that presentation and was invented by Merlin Mann. He even has a site on the subject; InboxZero.com. But he looks so crazy on that video that I didn’t dare watch it ;)

Here is a great presentation Merlin Mann did at Google....

Read More

TDD and legacy code

I have been doing some presentations on TDD and one thing that always happen is that you get some tricky questions in the beginning of the presentation.

As you’re introducing a new concept it of course starts very small and easy but most people directly try to put into their context, their normal situation.

And let’s admit it – there not very often we start off in a void, aka. a green field project. No – it’s mostly brown field - there is always code that exists that needs to be handled. What’s worse – that code is not written to be tested – Not Designed for Testability.

I think this is a very interesting subject and it touches on other subjects that I’m interesting on surrounding why it’s worth “clean up your room” (as Uncle Bob would have put it…)

There’s...

Read More

Trying Coding Dojo, Kata and Extreme OOP

In preparations for a presentation next week (which will go on for two days… brrr) I had my sights set on doing something about Extreme OOP or Object Calisthenics. I’m thinking of using that exercise to illustrate some OOP practices.

In the PDF-file for the Extreme OOP above you’ll find an excellent kata (the Commodore 64 kata) that will take you through all the rules of Object Calisthenics.

OK – but since I didn’t wanted to do that exercise all of my own I hooked up with two Avega colleagues (David Blomberg and Magnus Forberg, great guys!) and we did some kind of coding dojo.

The findings was quite surprising.

  • First – the rules of Object Calisthenics are not be followed when you do ordinary code. It’s simply an exercise to get you to think about OOP in a very structured...
Read More

Great tool for creating snippets

I love the snippet support in Visual Studio. It’s so much a part of what we do that we don’t even think about it anymore. Just like Intellisense way, way back – remember the time before that?

But one thing that always has been bit messy is to create your own. And that Snippet manager – what is that? I’ve never been able to get to like it.

But there is help on the way; meet Snippet Designer. It can help you not only to create snippets from existing code, but also to manage your snippets in a nice way.

Read More

Deploying ASP.NET MVC on IIS6

OK - this seems to be a problem that many people have run into. But for IIS 6 it seems to be some additional configuration that is needed in order to get ASP.NET MVC up and running.

First you’ll need to find the version of IIS. Yes, I know, it should be simple, but it’s not… Here is how you do it.

Then, when you know which one, and if it’s IIS6 or lower (i presume…) you can follow along nicely in this article by Gopinath - who saved my butt.

Read More

Red Beads and Limited WIP Society

I attended the second Limited WIP Society (Sweden) gathering. It’s a bunch of people that has taken liking in Kanban practices.

This evening David J Andersson joined us and he gave a very interesting presentation on Kanban teams reach CMMI 5 level, i.e. ranked as very mature. This is, apparently, not repeated by team doing other agile methods.

OK – during the second half me and Joakim Sundén presented the Red Bead Experiment. Well played it out I think would be a more appropriate word for it. It’s a game that aims to drive home the point Dr. W. Edwards Deming - “a bad system will beat a good person every time”

If you haven’t seen it before there is an excellent recording with Benjamin Mitchell and David Joyce.

Read More