Google Code: Open Source Web Frameworks == $$$$
Mar 18

Learning via Unit Tests

Tech Add comments

Mike Clark talks about how he learnt Ruby via tests.

This is one ways in which I learn new tech/APIs too.

  1. For simple exploration, play in an interactive shell
  2. For more, start writing tests

This is definitely valuable in its own right, but what if we all started to shall our test suites?

Wouldn’t it be nice to have a few suites for Hibernate 3 say. You could download the tests which would have examples of the various parts and pieces of Hibernate (simple one-one test, simple one-many, ….).

We do have test suites from the open source technologies themselves, and they are great resources, but this would have a very different audience.

Also, what if there were also test suites which have all methods throw new RuntimeException("Not Yet Implemented"). You, the developer, would then go through and try to get as many tests to pass as possible, learning all along the way!

We are actually trying to package some of this ourselves as it would be such a cool resource.

One Response to “Learning via Unit Tests”

  1. Simon P. Chappell Says:

    Dion,

    I’ve been attacking an aspect of this problem myself with a little program I hacked together.

    http://simonpeter.com/technology/software/babel/

    In fact I’m in the process of using it to learn Groovy and hope to create a informal open-source/free language test suite in the process.

    Simon

Leave a Reply

Spam is a pain, I am sorry to have to do this to you, but can you answer the question below?

Q: What are the first four letters in the word British?

Loading...