Greg Hewgill (ghewgill) wrote,
Greg Hewgill

test driven development

As I've been working on shaback, I've been wanting a faster way of doing testing. Since shaback uses the Amazon S3 service, it takes a certain minimum amount of time (due to latency) to do any operation, and it adds up quickly for lots of tests.

So, my solution is to implement a local server that acts like S3 for testing purposes. I found out about Park Place, but I'd like a solution in Python that doesn't require any nonstandard dependencies. Since this server is going to be part of a testing framework itself, a lightweight solution is desireable.

I thought this project would be a good one on which to practice TDD. So I set up a unit test framework using Python's unittest, and I've been doing strictly test-first development (that is, don't write code until you have a failing test). I've been editing the server code and test code side-by-side in my editor:

This is a bit different than the way I normally develop software, but I think it's good practice to try different methods. So far it's going well.


  • foiled again

    So I finished my earthquake widget about a week or so ago. I was waiting to send it to the Yahoo Widget Gallery so that the screen snapshot they…

  • email address obfuscation

    At the bottom of each of my web pages, I have a footer that looks something like this: Greg Hewgill Having my email…

  • minilink reaches 10k links

    The minilink ( link shortening service first went online in october 2004. Today, a milestone was passed - there have been more than 10,000…

  • Post a new comment


    Anonymous comments are disabled in this journal

    default userpic

    Your reply will be screened

    Your IP address will be recorded