Reputation: 105067
I am looking for a testing framework that allows me to have:
Is there anything that is able to accomplish this? I find it awkward that with all this trend around testing and tdd, the tools at our disposal are still so primitive and raw.
Upvotes: 4
Views: 315
Reputation: 18237
Using MSTest
For 1: Different kinds(categories) of tests
If you own ReSharper you can group tests based on TestCategory in their test running. (highly recommend ReSharper if you don't have it. You can use it free for 30 days to try it out).
If you don't then use the [Priority(int)] attribute, which you can group by in Visual Studios test runner.
Unfortunetly, using priority, you cannot have multiple tags on a single test.
Upvotes: 0
Reputation: 136613
NUnit
Upvotes: 1
Reputation: 19181
You should use the Gallio if you have resharper.
It supports any framework you might choose.
It will help your productivity a lot.
Upvotes: 1
Reputation: 99730
Upvotes: 4
Reputation: 2799
Using MSTest (some options to help if the others don't work out)
You can have TestCategories (using the TestCategory attribute) then use the filters at the top of the Test List Editor to pick out what you want.
You can also create ordered test lists by right clicking the project/folder, click new test at the top and it is one of the options. You then add and order the tests in the batch and it will run them sequentially and optionally fail the rest when one in the sequence fails.
My tests have been running sequentially, so as someone else mentioned you may just need to set the concurrency to 1, but I haven't done it myself.
Upvotes: 1
Reputation: 108995
VS's unit testing does 1, 2 and 4.
Different kinds(categories) of tests.
You can create multiple test lists by adding multiple "test settings" items, each can run different configurations or a different subset of your tests.
Run tests sequentially.
YOU Can control the level of concurrency used, including setting it to 1. (This does require editing an XML file, but is covered on MSDN).
Have some kind of support in Visual Studio for all of this. I
That's the easy one.
Have the option to have several tests depend on each other.
That's the hard one, as TDD best practice is for tests to be independent tools seem to assume this.
Within one class of tests keep flags and immediately exit tests where conditions have not been met.
Upvotes: 3