c++ - Is there a gtest equivalent for fixture-level setup/teardown? -
so, know there's "literally" fixtures gtest, constructor/destructor , setup/teardown functions execute after each test rather after entire set of tests in fixture.
i can think of ways of hacking around this, there built-in support i'm not finding?
you can define static methods setuptestcase
, teardowntestcase
in test fixture class. more information on in googletest wiki.
be careful spelling of these static method names.
Comments
Post a Comment