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 /examples/cppunittest/ExceptionTest.cpp | |
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 'examples/cppunittest/ExceptionTest.cpp')
-rw-r--r-- | examples/cppunittest/ExceptionTest.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/examples/cppunittest/ExceptionTest.cpp b/examples/cppunittest/ExceptionTest.cpp index c3d1876..c703c7d 100644 --- a/examples/cppunittest/ExceptionTest.cpp +++ b/examples/cppunittest/ExceptionTest.cpp @@ -33,10 +33,10 @@ ExceptionTest::tearDown() void ExceptionTest::testConstructor() { - const CppUnit::Message message( "a message" ); - const CppUnit::SourceLine sourceLine( "dir/afile.cpp", 17 ); + const CPPUNIT_NS::Message message( "a message" ); + const CPPUNIT_NS::SourceLine sourceLine( "dir/afile.cpp", 17 ); - CppUnit::Exception e( message, sourceLine ); + CPPUNIT_NS::Exception e( message, sourceLine ); CPPUNIT_ASSERT_EQUAL( message.shortDescription(), e.message().shortDescription() ); CPPUNIT_ASSERT( sourceLine == e.sourceLine() ); @@ -46,9 +46,9 @@ ExceptionTest::testConstructor() void ExceptionTest::testDefaultConstructor() { - CppUnit::Exception e; + CPPUNIT_NS::Exception e; - CPPUNIT_ASSERT( CppUnit::Message() == e.message() ); + CPPUNIT_ASSERT( CPPUNIT_NS::Message() == e.message() ); CPPUNIT_ASSERT( !e.sourceLine().isValid() ); } @@ -56,9 +56,9 @@ ExceptionTest::testDefaultConstructor() void ExceptionTest::testCopyConstructor() { - CppUnit::SourceLine sourceLine( "fileName.cpp", 123 ); - CppUnit::Exception e( CppUnit::Message("message"), sourceLine ); - CppUnit::Exception other( e ); + CPPUNIT_NS::SourceLine sourceLine( "fileName.cpp", 123 ); + CPPUNIT_NS::Exception e( CPPUNIT_NS::Message("message"), sourceLine ); + CPPUNIT_NS::Exception other( e ); checkIsSame( e, other ); } @@ -66,9 +66,9 @@ ExceptionTest::testCopyConstructor() void ExceptionTest::testAssignment() { - CppUnit::SourceLine sourceLine( "fileName.cpp", 123 ); - CppUnit::Exception e( CppUnit::Message("message"), sourceLine ); - CppUnit::Exception other; + CPPUNIT_NS::SourceLine sourceLine( "fileName.cpp", 123 ); + CPPUNIT_NS::Exception e( CPPUNIT_NS::Message("message"), sourceLine ); + CPPUNIT_NS::Exception other; other = e; checkIsSame( e, other ); } @@ -77,16 +77,16 @@ ExceptionTest::testAssignment() void ExceptionTest::testClone() { - CppUnit::SourceLine sourceLine( "fileName.cpp", 123 ); - CppUnit::Exception e( CppUnit::Message("message"), sourceLine ); - std::auto_ptr<CppUnit::Exception> other( e.clone() ); + CPPUNIT_NS::SourceLine sourceLine( "fileName.cpp", 123 ); + CPPUNIT_NS::Exception e( CPPUNIT_NS::Message("message"), sourceLine ); + std::auto_ptr<CPPUNIT_NS::Exception> other( e.clone() ); checkIsSame( e, *other.get() ); } void -ExceptionTest::checkIsSame( CppUnit::Exception &e, - CppUnit::Exception &other ) +ExceptionTest::checkIsSame( CPPUNIT_NS::Exception &e, + CPPUNIT_NS::Exception &other ) { std::string eWhat( e.what() ); std::string otherWhat( other.what() ); |