mirror of
https://github.com/catchorg/Catch2.git
synced 2024-12-23 03:43:28 +01:00
Fix for GitHub issue #56
TEST_CASE_METHOD's put the generated class into the anonymous namespace
This commit is contained in:
parent
f51d316dba
commit
d207cecade
@ -139,11 +139,12 @@ private:
|
||||
|
||||
///////////////////////////////////////////////////////////////////////////////
|
||||
#define TEST_CASE_METHOD( ClassName, TestName, Desc )\
|
||||
struct INTERNAL_CATCH_UNIQUE_NAME( Catch_FixtureWrapper ) : ClassName \
|
||||
{ \
|
||||
void test(); \
|
||||
}; \
|
||||
namespace{ Catch::AutoReg INTERNAL_CATCH_UNIQUE_NAME( autoRegistrar ) ( &INTERNAL_CATCH_UNIQUE_NAME( Catch_FixtureWrapper )::test, TestName, Desc, __FILE__, __LINE__ ); } \
|
||||
namespace{ \
|
||||
struct INTERNAL_CATCH_UNIQUE_NAME( Catch_FixtureWrapper ) : ClassName{ \
|
||||
void test(); \
|
||||
}; \
|
||||
Catch::AutoReg INTERNAL_CATCH_UNIQUE_NAME( autoRegistrar ) ( &INTERNAL_CATCH_UNIQUE_NAME( Catch_FixtureWrapper )::test, TestName, Desc, __FILE__, __LINE__ ); \
|
||||
} \
|
||||
void INTERNAL_CATCH_UNIQUE_NAME( Catch_FixtureWrapper )::test()
|
||||
|
||||
#endif // TWOBLUECUBES_CATCH_REGISTRY_HPP_INCLUDED
|
||||
|
Loading…
Reference in New Issue
Block a user