Search code examples
unit-testingdata-analysis

Unit testing...should it be used here?


Duplicate: https://stackoverflow.com/questions/135651/learning-unit-testing


I'm trying to develop some software for my research group to analyze and plot experimental data. I would like to make it where it's pretty error free. Would this be a situation for unit testing? If so could you possibly point me to some good references for unit testing?


Solution

  • Pretty much any code is a good candidate for unit testing; it will help you document the intent of your code, and prove that your code works as intended. It will definitely help you find bugs before releasing your code to the rest of your group. You don't say what platform you're using, so I can't recommend a testing framework, but I can recommend Kent Beck's excellent Test Driven Development: By Example as a good general starting place.