I fully typed out a question before spotting a potential duplicate in the Similar Questions list.
The existing question has been downvoted to -1 but has an unaccepted answer which, I believe, answers the existing question and my question.
Is it acceptable to post my question in hopes that it aids people looking for the same answer that might not spot the downvoted question with unaccepted answer? I could of course also refer to this existing question in mine.
For reference, my draft question reads as follows:
How can I share common tests across solutions?
If I have C# project containing "Tests About Tests" - used for example, to enforce that all test classes should end with "Tests" or that every class should have a corresponding test class - how can I share that project between multiple solutions so that the tests are identified and run by my test runner?
Solutions I've considered:
- Add the common tests as a dll/nuget reference - nunit/ncrunch doesn't appear to pick up the extra tests.
- Use externals in svn so the project itself can be shared between solutions - I believe this would work but not sure if there's an equivalent for git
- Add the project directly from a common location to every solution that requires it - Again this would work but is a bit brittle as it requires developers to use a particular structure when checking out solutions from source control.
Is there a better way? It would be great if the first option would work as it feels like the correct one but equally the second option is feasible if git has a similar concept to svn externals (although I'm still not a huge fan of this approach!)