New Community Website

Ordinarily, you'd be at the right spot, but we've recently launched a brand new community website... For the community, by the community.

Yay... Take Me to the Community!

The Community Blog is a personal opinion of community members and by no means the official standpoint of DNN Corp or DNN Platform. This is a place to express personal thoughts about DNNPlatform, the community and its ecosystem. Do you have useful information that you would like to share with the DNN Community in a featured article or blog? If so, please contact .

The use of the Community Blog is covered by our Community Blog Guidelines - please read before commenting or posting.

Gleanings From the Wet Coast - Agile and TDD

This Blog is the first in a series of Blogs that I intend to write about new concepts and ideas that I discover in my travels through .NET.  These will not neccessarily be my ideas - in fact most of them won't be, but I hope you will find them interesting and useful for your own development projects.

A few weeks ago when the new codeplex-based DNN Forge was introduced, I created a project that I called "The Family Tree project".  I have been working off-and-on for about 3 years on both a GEDCOM parser and a rich Object Model for managing Family Tree information.  The problem I had with this project is that early on I had taken a Waterfall approach to the design, and as this was a hobby project - and therefore I had limited time to work on it - the progress was painfully slow.

On Friday, after returning from the MVP summit and seeing all the cool new stuff coming along as well as a new emphasis on Test Driven Development, I decided to take a new approach to this project.

I decided to start anew - using an Agile development process.  Why an Agile process?  My previous efforts resulted in poor progress as the tasks seemed so large to complete, and so I always found excuses to do something more interesting.  Using an Agile process I can work on a single feature (eg List all Individuals) and get that feature working at all levels, before moving on to the next feature.

Andrew had recently downloaded Rob Conery's videos where he uses a TDD approach to rewiting the Commerce Starter Kit using MVC.  So we decided to try using TDD (Test Driven Development) ourselves on this project.  As I expect the project to take some time to complete, we also deccided to build it in ASP.NET 3.5 using the latest bits.

On Saturday, Andrew and I spent most of the day "Pair-Programming" the first "feature" - List Individuals.  In about 6 hrs we were able to complete all the tests to test all layers of the application, from the View down to the database for this single feature. 

So even before we actually browsed to the page we were pretty confident that everything would work - and it did.  Next we added the tests for "View" a single Individual.  As we had built much of the framework and hooks between the layers, this took less than an hour to complete, and again once we knew all the tests worked we were quite confident that browsing to the site would work and it did.  These two features, which are essentially feature complete (although all we are returniing is a first name and last name for each individual) resulted in 28 tests.  It really is cool to see all those green lights each time you make a change.

Although, you might think that TDD is more time-consuming as you have to write a whole bunch of test code - I think these results demonstrate that you can be productive - as you can be confident - if each test continues to pass - that new work does not break what you have already completed.

It is hard to convert an existing project like DNN to Test Driven Development - but I would urge you to consider this approach when starting new projects.

In future Blogs in this series I will share with you my "Gleanings" as we work through the  project.  Below is a list of some of the decisions we have made about what we will use for this project, but as we are being Agile this is just a first stab.

  1. Use a TDD development approach to test ALL Layers of the Application.
  2. Use MoQ as a Mocking Framework to help in the testing - we will also use a Web testing framework like WATIN or WebAii, so we can automate tests on the "browser" part of the equation.
  3. Use an IoC (Inversion of Control) Container
  4. Use all the new syntax sugar in C# 3.0 like Extension methods, Lambda Expressions, LINQ  - sorry, I do all my non-dnn development in C# so I can keep up to date in both languages.
  5. Use LINQ in the Data Layer (LINQ to SQL for now - but we may switch to LINQ to NHibernate or LINQ to Entities)
  6. Build an MVC-based Website front end - Initially this part of the project is mainly designed as a learning experience, but this may become a full-blown application
  7. Create an MVP (Module View Presenter) style Module for DNN (see Phil's blogs on this approach to Module Development)
  8. Expose a Web Services Interface for Silverlight (RIA) and WPF (Windows) clients


Comment Form

Only registered users may post comments.


Aderson Oliveira (22)
Alec Whittington (11)
Alessandra Davies (3)
Alex Shirley (10)
Andrew Hoefling (3)
Andrew Nurse (30)
Andy Tryba (1)
Anthony Glenwright (5)
Antonio Chagoury (28)
Ash Prasad (37)
Ben Schmidt (1)
Benjamin Hermann (25)
Benoit Sarton (9)
Beth Firebaugh (12)
Bill Walker (36)
Bob Kruger (5)
Bogdan Litescu (1)
Brian Dukes (2)
Brice Snow (1)
Bruce Chapman (20)
Bryan Andrews (1)
cathal connolly (55)
Charles Nurse (163)
Chris Hammond (213)
Chris Paterra (55)
Clint Patterson (108)
Cuong Dang (21)
Daniel Bartholomew (2)
Daniel Mettler (181)
Daniel Valadas (48)
Dave Buckner (2)
David Poindexter (12)
David Rodriguez (3)
Dennis Shiao (1)
Doug Howell (11)
Erik van Ballegoij (30)
Ernst Peter Tamminga (80)
Francisco Perez Andres (17)
Geoff Barlow (12)
George Alatrash (12)
Gifford Watkins (3)
Gilles Le Pigocher (3)
Ian Robinson (7)
Israel Martinez (17)
Jan Blomquist (2)
Jan Jonas (3)
Jaspreet Bhatia (1)
Jenni Merrifield (6)
Joe Brinkman (274)
John Mitchell (1)
Jon Henning (14)
Jonathan Sheely (4)
Jordan Coopersmith (1)
Joseph Craig (2)
Kan Ma (1)
Keivan Beigi (3)
Kelly Ford (4)
Ken Grierson (10)
Kevin Schreiner (6)
Leigh Pointer (31)
Lorraine Young (60)
Malik Khan (1)
Matt Rutledge (2)
Matthias Schlomann (16)
Mauricio Márquez (5)
Michael Doxsey (7)
Michael Tobisch (3)
Michael Washington (202)
Miguel Gatmaytan (3)
Mike Horton (19)
Mitchel Sellers (40)
Nathan Rover (3)
Navin V Nagiah (14)
Néstor Sánchez (31)
Nik Kalyani (14)
Oliver Hine (1)
Patricio F. Salinas (1)
Patrick Ryan (1)
Peter Donker (54)
Philip Beadle (135)
Philipp Becker (4)
Richard Dumas (22)
Robert J Collins (5)
Roger Selwyn (8)
Ruben Lopez (1)
Ryan Martinez (1)
Sacha Trauwaen (1)
Salar Golestanian (4)
Sanjay Mehrotra (9)
Scott McCulloch (1)
Scott Schlesier (11)
Scott Wilkinson (3)
Scott Willhite (97)
Sebastian Leupold (80)
Shaun Walker (237)
Shawn Mehaffie (17)
Stefan Cullmann (12)
Stefan Kamphuis (12)
Steve Fabian (31)
Steven Fisher (1)
Timo Breumelhof (24)
Tony Henrich (3)
Torsten Weggen (3)
Tycho de Waard (4)
Vicenç Masanas (27)
Vincent Nguyen (3)
Vitaly Kozadayev (6)
Will Morgenweck (40)
Will Strohl (180)
William Severance (5)
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out
What is Liquid Content?
Find Out