I think I can see my parcel!

Huh?

Having had a few xmas parcels go astray en route from Australia to the UK (not to mention the horrendous cost of postage), a colleague suggested that I simply buy a few things from Amazon UK. Brilliant! Now why didn’t I think of that! Worked so well, I sent two shipments. I came across this image today, and wanted to share it: Amazon UK at xmas! If only software could be written that way…

Microsoft up to its old Tricks?

Just when I was starting to be a Microsoft champion and truly believe they had turned over a new leaf, they go and do something like this: Microsoft tries to claim a patent on RSS (just a few days ago). This is ridiculous and disgraceful! Everyone knows that Microsoft did NOT invent RSS! In fact, they were relatively slow to adopt support for RSS into their products. MS, you need to get those patent guys under control, before they seriously start damaging your newfound credibilty.

What Developers Want

Rob Walling has posted an article, Nine Things Developers Want More Than Money, that managers should read, if they want to understand what makes most developers tick. Rob draws upon Frederick Herzberg’s Two Factor Theory.

Just over 1 year ago I left a job at an engineering company in Perth (with its head office in Canada). In the space of just 10 months, before and after I left, my department had a turn over of its entire complement of staff. I mention this, because all of the problems and complaints voiced by the developers are discussed in this post. [This one’s for you Bernie!] On the positive side, everyone that left found better jobs.

Over to You!

With the New Year quickly approaching, it’s not unusual to find people thinking about changing positions or jobs and with that in mind Rob Farley has posted an intelligent and insightful piece of the subject of handing over one’s responsibilities at the end of an employment.

I really like Rob’s suggestion that a handover be ‘practised’. It’s a bit like factoring in ‘mock’ database backup restores into an overall risk strategy plan (I have witnessed first hand, 2 large engineering companies being caught short, by not checking that there was actually something on those backup tapes, that they were sending offsite to a fire safe for 2 years!)

Bloated, Forgettable Software Dripping with Mediocrity!

OK, hopefully that title got your attention! More about it later…

I’m starting to realise that a technique I’ve successfully used to build applications in the past is closer to Test Driven Development than I had imagined. Namely creating paper based screen mockups, acting these through putting yourself in place of the user, and then building live prototypes. Let me begin at the beginning…

Last week I purchased an e-book from 37Signals, “Getting Real: the smarter, faster, easier way to build a successful web application”. It cost US19 (approx. AUS25) and was well worth the money. But check this out; you can even read it for free here! Free! How cool is that?

It says ‘web’ in the title, but it is equally applicable to non-web based software. The idea is to minimise non-executable artifacts (i.e. not actually running in the application), such as doco, diagrams etc…This is very similar to the theme that runs through agile development.

  • It’s about staying small (and agile).
  • It’s about less of everything that’s not essential.
  • You start with the interface, the actual screens that users will interact with.
  • It’s about short iterations (just like agile), and reducing the cost of change.
  • And more specifically, it’s about delivering just what customers need (just like agile).

Just like TDD, we deliver better results because we are forced to think about the actual problems we are trying to solve, rather than our ideas about how they should be solved.

[I did a short stint at a home loan company where they did things the opposite way: create a load of throw away, static mock up screens rather than real pages, and produce documentation that is out of date the minute you publish it. But I digress…]

I was amused to see a quote from the Elements of Style, on vigorous writing, as I blogged about the similarities in the process of software development and ‘good’ writing a while ago here.

One description that really stuck in my mind was: bloated, forgettable software dripping with mediocrity. Gotta love that for a put down!

OK, so we come to the central tenet of this eBook: you don’t need tons of money or a huge team or a lengthy development cycle to build great software. Less software, less code, less mass. More simplicity for your users. More user buy-in and more users who are passionate about your product.

Here is some of the condensed ‘Getting Real’ advice:

Use a team of three for Version 1.0
Start with a developer, a designer and someone who straddles both worlds. Starting with a small team will force you to make trade-off decisions early in the development process. Such a small team will communicate more effectively and efficiently than a larger one.

Let limitations be your guide to creative solutions
You are never going to have enough of all the things you would like; be it time, money, people etc. Don’t worry! Constraints are great for driving innovation and putting the brakes on ‘feature creep’

What does your application stand for?
What makes it different than other similar products? Why is there a need for it? Before you even think about coding you need to know the purpose of the product you are going to build – the vision.

Ignore details early on
Always work from large to small. Let the details reveal themselves as you use what you are building.

“Getting Real” continues for a good 130 pages more than I’ve briefly skimmed over here. It’s worth a read.

Got a Minute?

I came across this One Minute How-to podcast site while browsing my feedburner stats. It’s a great idea and not unlike the theme behind DailyDevelopers, with an even larger range of topics. I love the idea of explaining something in just a minute!

Test Driven Development (TDD) in a Nutshell

Here’s a brief overview of TDD:

  1. Write a test that fails (it fails because code that it tests is not written yet)
  2. Write just enough code so that the test passes
  3. Re-factor the code
  4. Repeat from step 2 until code is baked, then repeat from step 1.

Brief guidelines for good unit tests:

  • Write simple tests (if a test requires complex configuration and setup, it will eventually fall into disrepair).
  • Test one scenario at a time.
  • Tests are your specifications. Well written tests provide working specification of the code they test.
  • Name your tests accurately and consistently.
  • Use data that makes tests easy to read and understand.
  • Write tests that run quickly.
  • Make each test independent. You should be able to run them in any order.

The initial result of TDD is that you end up with a suite of tests to rely upon when you refactor your code. It gives you the courage to refactor freely and courageously, knowing that you have a ‘safety net’ that will tell you if you have broken existing functionality (providing you have sufficient test code coverage). But TDD also forces you to think like a consumer of your own code, with the positive side effect of producing cleaner, simpler designs.

The TDD sequence is often represented as follows (Note: Not the usual sequence for traffic lights!):

  • Red: Write a test (that fails)
  • Green: Write code to make test pass
  • Amber: Refactor until Green again, then repeat back at Red

Here are a few resources:

Books:
Test Driven Development: Kent Beck. Addison-Wesley.
Refactoring: Martin Fowler. Addison-Wesley.

Web:
http://www.agiledata.org/essays/tdd.html
Test-Driven Development in .NET by Peter Provost. An easy to understand introduction to TDD and unit testing.

Book Review: Pro C# 2005 and the .Net Platform, Third Edition by Andrew Troelsen


Pro C# 2005 and the .NET 2.0 Platform, Third Edition

This book is clear, well written and does not sacrifice any depth despite its broad coverage. Although targeted at developers with a few years experience, it is one of those rare books that is good no matter what your level of experience. The style is very polished and the book’s topics flow easily into one another.

One notable and surprising omission of .Net version 2.0 features was the BackgroundWorker class. This is a very useful feature of .Net 2.0

This is one of two Apress books that I purchased 6 months ago, after researching what books were on offer for version 2.0 of the .Net framework (the other was Pro ASP.NET 2.0, which I hope to post a short review presently). As an aside, I’m not sure whether Apress still offer this, but when I purchased this book I was also able to download a free, fully searchable eBook as well.