I have a large project for which I am attempting to use TDD. I am using Tut as my test framework, which has its flaws but is sufficient for what I need.
I need to exploit link time test seams, each test must be in its own executable. The project for this executable then launches itself as a post build step.
Unfortunately, this means that my Visual Studio Sln is filling up with tests, which is not scalable and also hides the actual important projects.
Does anyone know of a better way of running these tests? Is it possible to hide projects from a build and yet still have them build?
"Is it possible to hide projects from a build and yet still have them build?"
You can make separate solution for test cases. Then you can set up post build step of your main projects. This post-build should build tests-projects via separate solution and run them. Building test-projects should be done via command line (see e.g. here for details).
If you need to link your unit tests with some lib-s from main projects, you can use
#pragma comment(lib, "libname")
See this MSDN page for details.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With