Calling Unit Tests from other Unit Tests RRS feed

  • Question

  • I was just curious of some best practices regarding calling Unit Tests from other Unit Tests.  I will delve into the specifics if necessary, but I'm in general having issues calling TestMethods that are in separate TestClasses from each other.
    Friday, July 10, 2009 3:16 PM


  • At first glance, this does not seem like a good idea.

    If we have common code to set up or work with unit tests, we put them into a component shared by all unit testing components.

    But calling unit tests from other unit tests seems like it defeats part of the purpose in that you are no longer testing a unit. And you are creating dependencies that may make it harder to work with the tests over time.
    www.insteptech.com ; msmvps.com/blogs/deborahk
    We are volunteers and ask only that if we are able to help you, that you mark our reply as your answer. THANKS!
    Friday, July 10, 2009 4:24 PM