Thursday, July 19, 2007

TDD? You've got to be kidding me?

Just taking another peek over to the the Sun's side of the Sun/Microsoft fence and checking the color of their grass.

Another tool for testing the reliability of your tests is Jester. This tool will actually tweak your code as your unit tests are executed to see how well the tests hold up to changes.

There's already a C# port named Nester. I'm definitely going to try to integrate this into my CI process.

I have to admit, this isn't going to be funny (heh, wocka-wocka-wocka) the first couple times but it'll be interesting to see where it takes my code.

Submit this story to DotNetKicks

If yer code ain't tested, the waterfallists win.

Just reporting on untested code is nothin'. How about a tool that *removes* untested code.

Check out the oh-so-provocatively named coverage tool, Guantanamo.

When Guantanamo detects untested code it will actually remove it from a working copy of the codebase. C'mon, if you want to move from the foo-foo world of XP and into the hardcore world Mountain Dew level of extreme it should remove the code from source control. Currently the tool is only available in the Java world, but with most of the XP tools stack (ant, junit, cruisecontrol, jcover) will eventually find it's way into the C# world.

If you're wondering about the quality of your unit tests, and are in the Java world, check out Ashcroft. The same guy who gave us Guantanamo also created this tool for analyzing your unit tests. By checking your tests against a set of guidelines your testing practices become more focused and streamlined.

They are building a 10 Commandments of Unit Tests, here's a direct quote from their site.

  1. I am the class being tested. Thou shalt not test any other class but me.
  2. [Thou shalt write isolated tests]
  3. [Thou shalt not access files during unit tests]
  4. [Thou shalt not write two tests which depend upon each other]

This is good stuff, and I'm looking forward to more of these kinds of tools in the .NET world. Sure we have VS.NET and it's a great tool, but it seems like everything we have is clones of stuff from the Java universe. Are there any tools really unique to .NET that didn't originate as a direct reimplementation of a Java tool?

Submit this story to DotNetKicks

Monday, July 16, 2007

Know what's cool? Blogging from your installer is cool.

The pendulum is swinging back towards Linux again for me. As my wife has noticed and much to her irritation, every couple months I'll take another shot at replacing my Microsoft... er, I misspelled that, I meant Micro$haft (now I'm 133t), operating systems with one of the more popular Linux distributions. Over the years I've tried Red Hat (v4 was my first attempt), SuSE, Mandrake, Lindows (I think it's now called Linspire), Caldera (now SCO, those bastards) and an old Corel distribution. Mostly with varied levels of failure. Until Red Hat started the Fedora project, most of my attempts at converting to Linux we immediate dismal failures at best. There was always some level of ridiculous flakiness or some quirk that would irritate me enough to throw my hands up and run back to the known-devil that is Windows.

My current experiment is with Ubuntu 7.04, installed with the DVD included in a Linux Format magazine. The magazine is an excellent read and worth picking up even if you're a hardcore MS developer. But to make their magazine even cooler, each issue contains a content disc that usually has the latest version of several distributions. It's much easier just to spend the $15 and read the magazine while the installation chugs along, than to fight with downloading an ISO and discovering it was corrupt only after you began the install. But the magazine isn't why I'm blogging. I'm blogging because I am so throughly blown away by the Ubuntu installation experience.

Ubuntu has an amazing installer. They load the operating system as a live cd, basically running the OS directly from the DVD. You can then play around with the distribution before you fully commit to installing the OS, and if you decide to commit you just click the "install" icon on the desktop. A few more clicks through the wizard and you are on your way to Ubuntuy Linux goodness. The really fun part is that you can surf the web while the installation is running because the live cd loads all the drivers automatically. So I was able to blog about how awesome the Ubuntu installation experience is while the installation is running! Neat! Funny that installing an OS could be easier than installing some common desktop application.

Submit this story to DotNetKicks