This project is read-only.

SpartanUnit Test Organization Question

Feb 22, 2012 at 12:54 AM


  When writing our Unit tests, should we put them in the SpartanUnit.UnitTests.Root.TestControllerShould class?

Michael Heffernan

Feb 22, 2012 at 5:51 AM

Hi Michael,

You ask a very important question! SpartanUnit provides simple, powerful capabilities for organizing tests. But SpartanUnit does not specify how to use those capabilities. This is where OpenHopla has a role to play. A goal of OpenHopla is to demonstrate how to use SpartanUnit well.

Ultimately, how you decide to write your test cases, where you decide to put your test suite and test controller classes, how you decide to partition test cases across test suites, and how you decide manage test suites and test controllers via test controllers is up to you--just like how managing many of the files and folders on your computer hard drive is up to you. Some people are organized and disciplined about where they put things; others, not so much. To the extent that you wish to be a role model and contribute valuable examples of test cases, test suites, and test controllers to the OpenHopla project, you'll have to think carefully about how you want organize your tests. You'll have to anticipate future growth. And you'll have to ponder how to merge your contributions with the contributions that others have already made or may wish to make to OpenHopla in the future.

Where do you think you should put your tests? Why?