TDD Update

by Lord Cod3n 18. September 2008 10:14
Wow this gets complicated fast. I am still have trouble what kind of tests I should write. I am attempting to write a code Indexer with Search capabilities. Here is the list of Test Cases so far:
  • CodeManagerCanCreateInstanceOfFileManager
  • CodeManagerReturnsEmptyListWhenSearchTermNotProvided
  • CanGetAListOfFilesFromDirectory
  • CanGetListOfOnlyCodeFiles
  • CreateCodeFileObject

The main problem I have is trying to figure out how to move to the next test. The code is evolving and I feel confident after I make changes.  The code generation feels off.  I have created a Test List.  Some of the items I am currently researching include What goes in a Test Lest ?   Does it map to a Use Case?  Something the developer does?

Let me give an example of this one.  I am creating a test then I see a need for the FileManager object.  Do I then create a Test that makes me create the File Manager Object , or do I just create another test and implement the File Manager Class as a by product of that Test?

 Right now the Code has evolved to include the following objects :   (CodeFile,FileManager,CodeManager) using SoC(Separation of Concerns) I am attempting to isolate working with the File System.  The FileSystem object uses the System.IO namespace.  The CodeManager uses the FileManager to search the file system and Contains a List of CodeFiles.  

 

I am researching by reading the following book:

Test-Driven Development in Microsoft® .NET 

You can find it on amazon here

http://www.amazon.com/Test-Driven-Development-Microsoft-NET-Professional/dp/0735619484/ref=pd_bbs_sr_1?ie=UTF8&s=books&qid=1221783997&sr=8-1  

 

 More updates when the mood hits.

Bill 

 

 

 

 

Be the first to rate this post

  • Currently 0/5 Stars.
  • 1
  • 2
  • 3
  • 4
  • 5

Tags:

Comments

Powered by BlogEngine.NET 1.4.5.0
Theme by Mads Kristensen

About the author

William Moore is the lead Software Architect and Technologist for Coden Enterprises. He has more than a decade of software development experience primarily Microsoft Platforms.  William enjoys the full gamit of coding everything from the UI down to the database.

Most comments

Page List