Slashdot Mirror


Test Driven Development Examples?

esnyder queries: "I find the pragmatic/agile/XP hype about test driven development compelling, but find it hard to see how to test first (or even unit test at all) in some situations. I would like to explore some extended examples of it in a moderate to large scale real world codebase to improve my test design skills. Can anyone recommend some F/OSS software projects that consistently use test driven development processes that I could check out? Preferable over 50K lines of code, but I'd welcome pointers to anything that people think would be helpful."

2 of 74 comments (clear)

  1. Python by mbrubeck · · Score: 5, Informative

    The Python programming language and all of its standard library modules make extensive use of unit tests and TDD.

  2. Java example by jtheory · · Score: 4, Informative

    It would have been helpful if you'd mentioned the language you're using, and the types of applications (since of course both of those make a huge difference).

    If you're using Java for web development, I'd suggest reviewing the Struts Applications Project on SourceForge.

    It's a collection of documentation and applications using Struts that are really "done right" -- with documentation, sensible and scalable design, fully implemented testing (unit level AND on the HTTP level). I'm currently roaming through the AppFuse source in there -- it's basically designed to give you a complete setup to start building your app on, with common functions already built-in.

    From the site:
    AppFuse
    An application for starting your Struts-based applications. Checkout from CVS and execute "ant -Dapp.name=yourApp -Ddb.name=database" to instantly be up and running with a Tomcat/MySQL app. Uses Ant, XDoclet, Hibernate, JUnit, Cactus, StrutsTestCase, Canoo's WebTest, Struts Menu, Display Tag Library, JSTL and Struts (including Validator and Tiles). Features include CMA, Remember Me, Self Registration, Password Hint. The fuse to start your apps.

    --
    There are only 10 types of people: those who understand decimal, those who don't, and, uh, 8 other types I forget.