googletest (gtest) allows disable individual tests adding
disabled_
prefix test name.
what parametrized tests -- how disable those? adding prefix test name not disable them.
for example, how disable example test provided gtest documentation:
class footest : public ::testing::testwithparam<const char*> { // can implement usual fixture class members here. // access test parameter, call getparam() class // testwithparam<t>. }; test_p(footest, hasblahblah) { ... } instantiate_test_case_p(instantiationname, footest, ::testing::values("meeny", "miny", "moe"));
you need add
disabled_
prefix instantiation name, this:
instantiate_test_case_p(disabled_instantiationname, footest, ::testing::values("meeny", "miny", "moe"));
Comments
Post a Comment