iveney / googletest

Automatically exported from code.google.com/p/googletest
BSD 3-Clause "New" or "Revised" License
0 stars 0 forks source link

Support Multiple Levels of TestCase Specification #60

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
As number of tests for an application grow very large, it would be 
difficult to organize the tests with two levels of grouping. It will be 
very useful if multiple levels of TestCases are supported.

It will provide more control using filters to specify which tests to run. 
Also it would be easier to navigate the output.

e.g. 

TEST(testCase, subTestCase1, subTestCas2, test1)
TEST(testCase, subTestCase1, subTestCas2, test2)
TEST(testCase, subTestCase1, test3)

Original issue reported on code.google.com by tmrao...@gmail.com on 31 Oct 2008 at 3:16

GoogleCodeExporter commented 9 years ago
Our experience is that in practice this is rarely a problem.  You can always 
structure your test case names to reflect the grouping:

TEST(testCase_subTestCase1_subTestCase2, test1).

If you look at the implementation of Google Test, you'll see that it will 
complicate 
the system a lot to implement multi-tiered tests.  We considered this when 
designing 
Google Test initially and decided not to do it.  It's more important to keep 
the API 
simple, which has paid off.

Original comment by shiq...@gmail.com on 31 Oct 2008 at 6:38