summaryrefslogtreecommitdiff
path: root/include/cppunit
diff options
context:
space:
mode:
authorBaptiste Lepilleur <gaiacrtn@free.fr>2002-07-13 10:36:33 +0000
committerBaptiste Lepilleur <gaiacrtn@free.fr>2002-07-13 10:36:33 +0000
commit0807889cb53679c5a9e741e8dedc3668ef59729b (patch)
tree86274bb4deed3450cbdf736b70357703ac13537b /include/cppunit
parentf1bf3276752a10a2cdf4e3cf3087399d199c4566 (diff)
downloadcppunit-0807889cb53679c5a9e741e8dedc3668ef59729b.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')
-rw-r--r--include/cppunit/Makefile.am2
-rw-r--r--include/cppunit/portability/CppUnitDeque.h28
-rw-r--r--include/cppunit/portability/CppUnitMap.h32
-rw-r--r--include/cppunit/portability/CppUnitVector.h28
-rw-r--r--include/cppunit/portability/Makefile.am6
5 files changed, 95 insertions, 1 deletions
diff --git a/include/cppunit/Makefile.am b/include/cppunit/Makefile.am
index adca29f..796817c 100644
--- a/include/cppunit/Makefile.am
+++ b/include/cppunit/Makefile.am
@@ -1,4 +1,4 @@
-SUBDIRS = extensions ui plugin config tools
+SUBDIRS = extensions ui plugin config tools portability
DISTCLEANFILES = config-auto.h
diff --git a/include/cppunit/portability/CppUnitDeque.h b/include/cppunit/portability/CppUnitDeque.h
new file mode 100644
index 0000000..781c43e
--- /dev/null
+++ b/include/cppunit/portability/CppUnitDeque.h
@@ -0,0 +1,28 @@
+#ifndef CPPUNIT_PORTABILITY_CPPUNITDEQUE_H
+#define CPPUNIT_PORTABILITY_CPPUNITDEQUE_H
+
+// The technic used is similar to the wrapper of STLPort.
+
+#include <cppunit/Portability.h>
+#include <deque>
+
+
+#if CPPUNIT_STD_NEED_ALLOCATOR
+
+CPPUNIT_NS_BEGIN
+
+template<class T>
+class CppUnitDeque : public std::deque<T,CPPUNIT_STD_ALLOCATOR>
+{
+public:
+};
+
+CPPUNIT_NS_END
+
+#else // CPPUNIT_STD_NEED_ALLOCATOR
+
+#define CppUnitDeque std::deque
+
+#endif
+
+#endif // CPPUNIT_PORTABILITY_CPPUNITDEQUE_H \ No newline at end of file
diff --git a/include/cppunit/portability/CppUnitMap.h b/include/cppunit/portability/CppUnitMap.h
new file mode 100644
index 0000000..24df4a5
--- /dev/null
+++ b/include/cppunit/portability/CppUnitMap.h
@@ -0,0 +1,32 @@
+#ifndef CPPUNIT_PORTABILITY_CPPUNITMAP_H
+#define CPPUNIT_PORTABILITY_CPPUNITMAP_H
+
+// The technic used is similar to the wrapper of STLPort.
+
+#include <cppunit/Portability.h>
+#include <functional>
+#include <map>
+
+
+#if CPPUNIT_STD_NEED_ALLOCATOR
+
+CPPUNIT_NS_BEGIN
+
+template<class Key, class T>
+class CppUnitMap : public std::map<Key
+ ,T
+ ,std::less<Key>
+ ,CPPUNIT_STD_ALLOCATOR>
+{
+public:
+};
+
+CPPUNIT_NS_END
+
+#else // CPPUNIT_STD_NEED_ALLOCATOR
+
+#define CppUnitMap std::map
+
+#endif
+
+#endif // CPPUNIT_PORTABILITY_CPPUNITMAP_H \ No newline at end of file
diff --git a/include/cppunit/portability/CppUnitVector.h b/include/cppunit/portability/CppUnitVector.h
new file mode 100644
index 0000000..f3157e6
--- /dev/null
+++ b/include/cppunit/portability/CppUnitVector.h
@@ -0,0 +1,28 @@
+#ifndef CPPUNIT_PORTABILITY_CPPUNITVECTOR_H
+#define CPPUNIT_PORTABILITY_CPPUNITVECTOR_H
+
+// The technic used is similar to the wrapper of STLPort.
+
+#include <cppunit/Portability.h>
+#include <vector>
+
+
+#if CPPUNIT_STD_NEED_ALLOCATOR
+
+CPPUNIT_NS_BEGIN
+
+template<class T>
+class CppUnitVector : public std::vector<T,CPPUNIT_STD_ALLOCATOR>
+{
+public:
+};
+
+CPPUNIT_NS_END
+
+#else // CPPUNIT_STD_NEED_ALLOCATOR
+
+#define CppUnitVector std::vector
+
+#endif
+
+#endif // CPPUNIT_PORTABILITY_CPPUNITVECTOR_H \ No newline at end of file
diff --git a/include/cppunit/portability/Makefile.am b/include/cppunit/portability/Makefile.am
new file mode 100644
index 0000000..c70aaf0
--- /dev/null
+++ b/include/cppunit/portability/Makefile.am
@@ -0,0 +1,6 @@
+libcppunitincludedir = $(includedir)/cppunit/portability
+
+libcppunitinclude_HEADERS = \
+ CppUnitDeque.h \
+ CppUnitVector.h \
+ CppUnitMap.h