diff options
| author | Baptiste Lepilleur <gaiacrtn@free.fr> | 2002-07-13 09:33:50 +0000 |
|---|---|---|
| committer | Baptiste Lepilleur <gaiacrtn@free.fr> | 2002-07-13 09:33:50 +0000 |
| commit | f1bf3276752a10a2cdf4e3cf3087399d199c4566 (patch) | |
| tree | 13dc67edcf465f44b9fe835f5e0b201511774d07 /include/cppunit/extensions/HelperMacros.h | |
| parent | 570132ec2707c8bac6c27c758254f05e293fe613 (diff) | |
| download | cppunit-f1bf3276752a10a2cdf4e3cf3087399d199c4566.tar.gz | |
Include/cppunit/ui/text/TestRunner.
include/cppunit/ui/text/TestRunner.h:
* src/cppunit/TextTestRunner.cpp: Renamed TextUi::TestRunner
TextTestRunner and moved it to the CppUnit namespace. Added
a deprecated typedef for compatibility with previous version.
* include/cppunit/ui/text/TextTestRunner.h: added.
* include/cppunit/ui/mfc/TestRunner.h:
* src/cppunit/msvc6/testrunner/TestRunner.cpp: Renamed MfcUi::TestRunner
MfcTestRunner. Added deprecated typedef for compatibility. Renamed
TestRunner.cpp to MfcTestRunner.cpp.
* include/cppunit/ui/mfc/MfcTestRunner.h: added.
* include/cppunit/ui/qt/TestRunner.h:
* src/qttestrunner/TestRunner.cpp: renamed QtUi::TestRunner QtTestRunner
and moved it to CppUnit namespace. Added a deprecated typedef for
compatibility. Renamed TestRunner.cpp to QtTestRunner.cpp.
* include/cppunit/ui/qt/TestRunner.h:
* src/qttestrunner/TestRunner.h: Moved TestRunner to CppUnit namespace
and renamed it QtTestRunner. Added deprecated typedef for compatibility.
* include/cppunit/Asserter.h:
* src/cppunit/Asserter.cpp: changed namespace Asserter to a struct and
made all methods static.
* include/cppunit/extensions/HelperMacros.h:
* include/cppunit/extensions/SourceLine.h:
* include/cppunit/extensions/TestAssert.h:
* include/cppunit/extensions/TestPlugIn.h:
* include/cppunit/Portability.h: changed CPPUNIT_NS(symbol) to a
symbol macro that expand either to CppUnit or nothing. The symbol is
no longer a parameter.
* include/cppunit/portability/CppUnitVector.h:
* include/cppunit/portability/CppUnitDeque.h:
* include/cppunit/portability/CppUnitMap.h: added. STL Wrapper for
compilers that do not support template default argumenent and need
the allocator to be passed when instantiating STL container.
* examples/cppunittest/*.h:
* examples/cppunittest/*.cpp:
* src/msvc6/testrunner/*.h:
* src/msvc6/testrunner/*.cpp:
* src/msvc6/testpluginrunner/*.h:
* src/msvc6/testpluginrunner/*.cpp:
* src/qttestrunner/*.h:
* src/qttestrunner/*.cpp: replaced occurence of CppUnit:: by CPPUNIT_NS.
* src/cppunit/TestSuite.h:
replaced occurence of std::vector by CppUnitVector.
Diffstat (limited to 'include/cppunit/extensions/HelperMacros.h')
| -rw-r--r-- | include/cppunit/extensions/HelperMacros.h | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/include/cppunit/extensions/HelperMacros.h b/include/cppunit/extensions/HelperMacros.h index 5d63f8b..379187f 100644 --- a/include/cppunit/extensions/HelperMacros.h +++ b/include/cppunit/extensions/HelperMacros.h @@ -22,7 +22,7 @@ CPPUNIT_NS_BEGIN { public: //! Creates a new TestFixture instance. - virtual CPPUNIT_NS(TestFixture) *makeFixture() =0; + virtual CPPUNIT_NS::TestFixture *makeFixture() =0; }; CPPUNIT_NS_END @@ -114,14 +114,14 @@ CPPUNIT_NS_END #define CPPUNIT_TEST_SUITE( ATestFixtureType ) \ private: \ typedef ATestFixtureType ThisTestFixtureType; \ - class __ThisTestFixtureFactory : public CPPUNIT_NS(TestFixtureFactory) \ + class __ThisTestFixtureFactory : public CPPUNIT_NS::TestFixtureFactory \ { \ - virtual CPPUNIT_NS(TestFixture) *makeFixture() \ + virtual CPPUNIT_NS::TestFixture *makeFixture() \ { \ return new ATestFixtureType(); \ } \ }; \ - static const CPPUNIT_NS(TestNamer) &__getTestNamer() \ + static const CPPUNIT_NS::TestNamer &__getTestNamer() \ { \ static CPPUNIT_TESTNAMER_DECL( testNamer, ATestFixtureType ); \ return testNamer; \ @@ -130,7 +130,7 @@ CPPUNIT_NS_END class ThisTestFixtureFactory \ { \ public: \ - ThisTestFixtureFactory( CPPUNIT_NS(TestFixtureFactory) *factory ) \ + ThisTestFixtureFactory( CPPUNIT_NS::TestFixtureFactory *factory ) \ : m_factory( factory ) \ { \ } \ @@ -139,16 +139,16 @@ CPPUNIT_NS_END return (ThisTestFixtureType *)m_factory->makeFixture(); \ } \ private: \ - CPPUNIT_NS(TestFixtureFactory) *m_factory; \ + CPPUNIT_NS::TestFixtureFactory *m_factory; \ }; \ \ static void \ - __registerTests( CPPUNIT_NS(TestSuite) *suite, \ - CPPUNIT_NS(TestFixtureFactory) *fixtureFactory, \ - const CPPUNIT_NS(TestNamer) &namer ) \ + __registerTests( CPPUNIT_NS::TestSuite *suite, \ + CPPUNIT_NS::TestFixtureFactory *fixtureFactory, \ + const CPPUNIT_NS::TestNamer &namer ) \ { \ const ThisTestFixtureFactory factory( fixtureFactory ); \ - CPPUNIT_NS(TestSuiteBuilder)<ThisTestFixtureType> builder( suite, namer ) + CPPUNIT_NS::TestSuiteBuilder<ThisTestFixtureType> builder( suite, namer ) /*! \brief Begin test suite (includes parent suite) @@ -272,7 +272,7 @@ CPPUNIT_NS_END * method. */ #define CPPUNIT_TEST_EXCEPTION( testMethod, ExceptionType ) \ - CPPUNIT_TEST_ADD( (new CPPUNIT_NS(TestCaller)<ThisTestFixtureType, \ + CPPUNIT_TEST_ADD( (new CPPUNIT_NS::TestCaller<ThisTestFixtureType, \ ExceptionType>( \ namer.getTestNameFor( #testMethod ), \ &ThisTestFixtureType::testMethod, \ @@ -294,7 +294,7 @@ CPPUNIT_NS_END * \see CreatingNewAssertions. */ #define CPPUNIT_TEST_FAIL( testMethod ) \ - CPPUNIT_TEST_EXCEPTION( testMethod, CPPUNIT_NS(Exception) ) + CPPUNIT_TEST_EXCEPTION( testMethod, CPPUNIT_NS::Exception ) /*! \brief Adds a custom test case. * @@ -398,10 +398,10 @@ CPPUNIT_NS_END #define CPPUNIT_TEST_SUITE_END() \ builder.takeSuite(); \ } \ - static CPPUNIT_NS(TestSuite) *suite() \ + static CPPUNIT_NS::TestSuite *suite() \ { \ - const CPPUNIT_NS(TestNamer) &namer = __getTestNamer(); \ - CPPUNIT_NS(TestSuiteBuilder)<ThisTestFixtureType> builder( namer ); \ + const CPPUNIT_NS::TestNamer &namer = __getTestNamer(); \ + CPPUNIT_NS::TestSuiteBuilder<ThisTestFixtureType> builder( namer ); \ __ThisTestFixtureFactory factory; \ ThisTestFixtureType::__registerTests( builder.suite(), &factory, namer ); \ return builder.takeSuite(); \ @@ -431,7 +431,7 @@ CPPUNIT_NS_END * CppUnit::TestFactoryRegistry. */ #define CPPUNIT_TEST_SUITE_REGISTRATION( ATestFixtureType ) \ - static CPPUNIT_NS(AutoRegisterSuite)< ATestFixtureType > \ + static CPPUNIT_NS::AutoRegisterSuite< ATestFixtureType > \ CPPUNIT_MAKE_UNIQUE_NAME(__autoRegisterSuite ) @@ -473,7 +473,7 @@ CPPUNIT_NS_END * CppUnit::TestFactoryRegistry.. */ #define CPPUNIT_TEST_SUITE_NAMED_REGISTRATION( ATestFixtureType, suiteName ) \ - static CPPUNIT_NS(AutoRegisterSuite)< ATestFixtureType > \ + static CPPUNIT_NS::AutoRegisterSuite< ATestFixtureType > \ CPPUNIT_MAKE_UNIQUE_NAME(__autoRegisterSuite )(suiteName) /*! Adds that the specified registry suite to another registry suite. @@ -504,7 +504,7 @@ CPPUNIT_NS_END * \see CPPUNIT_REGISTRY_ADD_TO_DEFAULT, CPPUNIT_TEST_SUITE_NAMED_REGISTRATION. */ #define CPPUNIT_REGISTRY_ADD( which, to ) \ - static CPPUNIT_NS(AutoRegisterRegistry) \ + static CPPUNIT_NS::AutoRegisterRegistry \ CPPUNIT_MAKE_UNIQUE_NAME( __autoRegisterRegistry )( which, to ) /*! Adds that the specified registry suite to the default registry suite. @@ -517,7 +517,7 @@ CPPUNIT_NS_END * \see CPPUNIT_REGISTRY_ADD. */ #define CPPUNIT_REGISTRY_ADD_TO_DEFAULT( which ) \ - static CPPUNIT_NS(AutoRegisterRegistry) \ + static CPPUNIT_NS::AutoRegisterRegistry \ CPPUNIT_MAKE_UNIQUE_NAME( __autoRegisterRegistry )( which ) // Backwards compatibility |
