[Mockpp-commits] mockpp/mockpp/tests AbstractDynamicChainingMock_test.cpp,1.33,1.34 AbstractInvocati
Brought to you by:
ewald-arnold
Update of /cvsroot/mockpp/mockpp/mockpp/tests In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv13126/mockpp/tests Modified Files: AbstractDynamicChainingMock_test.cpp AbstractInvocationDispatcher_test.cpp And_test.cpp AnyArgumentsMatcher_test.cpp ArgumentsMatchBuilder_test.cpp ArgumentsMatcher_test.cpp AssertMo_test.cpp Assert_test.cpp ChainableMockMethod_1_test.cpp ChainableMockMethod_2_test.cpp ChainableMockMethod_test.cpp ChainableMockObjectPolymorphism_test.cpp ChainableMockObject_1_test.cpp ChainableMockObject_1_void_test.cpp ChainableMockObject_2_test.cpp ChainableMockObject_2_void_test.cpp ChainableMockObject_3_test.cpp ChainableMockObject_3_void_test.cpp ChainableMockObject_4_test.cpp ChainableMockObject_4_void_test.cpp ChainableMockObject_5_test.cpp ChainableMockObject_5_void_test.cpp ChainableMockObject_test.cpp ChainableMockObject_void_test.cpp ChainingMockBuilder_test.cpp ChainingMockObjectSupport_test.cpp ConstraintList_test.cpp ConstraintSet_test.cpp CoreMock_test.cpp CustomStub_test.cpp DefaultResultStub_test.cpp DynamicChainingMockError_test.cpp Exception_test.cpp ExpectationBoundary_test.cpp ExpectationConglomeration_test.cpp ExpectationCounterRange_test.cpp ExpectationCounter_test.cpp ExpectationList_test.cpp ExpectationMap_test.cpp ExpectationSegment_test.cpp ExpectationSet_test.cpp ExpectationValue_test.cpp FIFOInvocationDispatcher_test.cpp Formatter_test.cpp InvocationMockerBuilder_test.cpp InvocationMocker_test.cpp Invocation_test.cpp InvokeAtLeastMatcher_test.cpp InvokeAtLeastOnceMatcher_test.cpp InvokeAtMostMatcher_test.cpp InvokeCountMatcher_test.cpp InvokeOnceMatcher_test.cpp InvokedAfterMatcher_test.cpp InvokedBeforeMatcher_test.cpp InvokedRecorder_test.cpp IsAnything_test.cpp IsCloseTo_test.cpp IsEqual_test.cpp IsGreaterOrEqual_test.cpp IsGreaterThan_test.cpp IsInstanceOf_test.cpp IsLessOrEqual_test.cpp IsLessThan_test.cpp IsNot_test.cpp IsNothing_test.cpp IsSame_test.cpp LIFOInvocationDispatcher_test.cpp Makefile.am MatchBuilder_test.cpp MixedMockObject_5_test.cpp MockObject_test.cpp NoArgumentsMatcher_test.cpp NoException_test.cpp Or_test.cpp OutBound_test.cpp ResponseVector_test.cpp ReturnObjectList_test.cpp ReturnStub_test.cpp SelectFramework.h StringContains_test.cpp StringEndsWith_test.cpp StringStartsWith_test.cpp StubBuilder_test.cpp StubSequence_test.cpp TestFailureMatcher_test.cpp TestFailureStub_test.cpp ThrowStub_test.cpp ThrowableList_test.cpp Throwable_test.cpp TimeServer_test.cpp TrackingCounter_test.cpp TypelessStubSequence_test.cpp UnlimitedMatcher_test.cpp Verifiable_test.cpp VerifyingTestCaller_test.cpp VerifyingTestCase_test.cpp VisitableMockMethod_1_test.cpp VisitableMockMethod_2_test.cpp VisitableMockMethod_test.cpp VisitableMockObject_1_test.cpp VisitableMockObject_1_void_test.cpp VisitableMockObject_2_test.cpp VisitableMockObject_2_void_test.cpp VisitableMockObject_3_test.cpp VisitableMockObject_3_void_test.cpp VisitableMockObject_4_test.cpp VisitableMockObject_4_void_test.cpp VisitableMockObject_5_test.cpp VisitableMockObject_5_void_test.cpp VisitableMockObject_template_test.cpp VisitableMockObject_test.cpp VisitableMockObject_void_test.cpp VoidStub_test.cpp mock_test.cpp mockpp_pti_test.cpp mockpp_test.cpp Log Message: switch unittest framework Index: Or_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/Or_test.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- Or_test.cpp 15 Oct 2005 15:40:59 -0000 1.11 +++ Or_test.cpp 9 Dec 2005 18:56:20 -0000 1.12 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/ChainingMockObjectSupport.h> @@ -42,12 +38,15 @@ #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class Or_test : public CppUnit::TestFixture +class Or_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( Or_test ); CPPUNIT_TEST(test_invoke); @@ -55,6 +54,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); @@ -62,7 +63,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(Or_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (Or_test); + +#endif // frameworks + void Or_test::test_describe() @@ -86,4 +94,4 @@ } -#endif // HAVE_CPPUNIT + Index: TestFailureMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/TestFailureMatcher_test.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- TestFailureMatcher_test.cpp 27 Nov 2005 17:27:57 -0000 1.9 +++ TestFailureMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.10 @@ -29,34 +29,42 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/TestFailureMatcher.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class TestFailureMatcher_test : public CppUnit::TestFixture +class TestFailureMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( TestFailureMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(TestFailureMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (TestFailureMatcher_test); + +#endif // frameworks + void TestFailureMatcher_test::test_invoke() @@ -92,4 +100,4 @@ } -#endif // HAVE_CPPUNIT + Index: DynamicChainingMockError_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/DynamicChainingMockError_test.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- DynamicChainingMockError_test.cpp 15 Oct 2005 15:40:58 -0000 1.15 +++ DynamicChainingMockError_test.cpp 9 Dec 2005 18:56:20 -0000 1.16 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/DynamicChainingMockError.h> #include <mockpp/chaining/AbstractDynamicChainingMock.h> @@ -42,29 +38,41 @@ #include <mockpp/constraint/ConstraintSet.h> -#include <cppunit/extensions/HelperMacros.h> namespace { -class DynamicChainingMockError_test : public CppUnit::TestFixture +class DynamicChainingMockError_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( DynamicChainingMockError_test ); CPPUNIT_TEST(test_describe); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(DynamicChainingMockError_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (DynamicChainingMockError_test); + +#endif // frameworks + template <typename R, typename I> class AID : public mockpp::AbstractInvocationDispatcher<R, I> @@ -108,4 +116,4 @@ } // namespace -#endif // HAVE_CPPUNIT + Index: AbstractDynamicChainingMock_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/AbstractDynamicChainingMock_test.cpp,v retrieving revision 1.33 retrieving revision 1.34 diff -u -d -r1.33 -r1.34 --- AbstractDynamicChainingMock_test.cpp 27 Nov 2005 17:27:57 -0000 1.33 +++ AbstractDynamicChainingMock_test.cpp 9 Dec 2005 18:56:20 -0000 1.34 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/AbstractDynamicChainingMock.h> #include <mockpp/chaining/InvocationMocker.h> @@ -46,7 +42,6 @@ #include <mockpp/chaining/ChainingMockObjectSupport.h> -#include <cppunit/extensions/HelperMacros.h> typedef mockpp::Invocation0 GetterInvocation; @@ -60,11 +55,15 @@ namespace { -class AbstractDynamicChainingMock_test : public CppUnit::TestFixture +class AbstractDynamicChainingMock_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( AbstractDynamicChainingMock_test ); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + + CPPUNIT_TEST_SUITE( AbstractDynamicChainingMock_test ); CPPUNIT_TEST( test_void_invocation ); CPPUNIT_TEST( test_invocation ); @@ -73,7 +72,9 @@ CPPUNIT_TEST( test_void_describe ); CPPUNIT_TEST( test_verify ); - CPPUNIT_TEST_SUITE_END(); + CPPUNIT_TEST_SUITE_END(); + +#endif public: @@ -86,7 +87,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION( AbstractDynamicChainingMock_test ); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION ( AbstractDynamicChainingMock_test ); + +#endif // frameworks + template <typename R, // Returntype @@ -423,4 +431,4 @@ } // namesspace -#endif // HAVE_CPPUNIT + Index: IsInstanceOf_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/IsInstanceOf_test.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- IsInstanceOf_test.cpp 27 Nov 2005 15:34:36 -0000 1.14 +++ IsInstanceOf_test.cpp 9 Dec 2005 18:56:20 -0000 1.15 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsInstanceOf.h> @@ -44,10 +40,14 @@ #ifndef MOCKPP_NO_RTTI -class IsInstanceOf_test : public CppUnit::TestFixture +class IsInstanceOf_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( IsInstanceOf_test ); CPPUNIT_TEST(test_invoke); @@ -55,6 +55,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); @@ -62,7 +64,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(IsInstanceOf_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (IsInstanceOf_test); + +#endif // frameworks + class A @@ -139,4 +148,4 @@ #endif // MOCKPP_NO_RTTI -#endif // HAVE_CPPUNIT + Index: ExpectationList_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ExpectationList_test.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- ExpectationList_test.cpp 13 Nov 2005 11:53:18 -0000 1.17 +++ ExpectationList_test.cpp 9 Dec 2005 18:56:20 -0000 1.18 @@ -29,21 +29,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationList.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class ExpectationList_test : public CppUnit::TestFixture +class ExpectationList_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ExpectationList_test ); CPPUNIT_TEST(test_chain); @@ -69,6 +68,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_expectNothing(); void test_expectNothing_revoked(); @@ -93,7 +94,14 @@ void fail_ifNoActual(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(ExpectationList_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ExpectationList_test); + +#endif // frameworks + void ExpectationList_test::test_chain() @@ -298,4 +306,4 @@ } -#endif // HAVE_CPPUNIT + Index: IsLessThan_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/IsLessThan_test.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- IsLessThan_test.cpp 15 Oct 2005 15:40:59 -0000 1.7 +++ IsLessThan_test.cpp 9 Dec 2005 18:56:20 -0000 1.8 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsLessThan.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class IsLessThan_test : public CppUnit::TestFixture +class IsLessThan_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( IsLessThan_test ); CPPUNIT_TEST(test_invoke); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(IsLessThan_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (IsLessThan_test); + +#endif // frameworks + void IsLessThan_test::test_describe() @@ -80,4 +88,4 @@ } -#endif // HAVE_CPPUNIT + Index: ExpectationMap_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ExpectationMap_test.cpp,v retrieving revision 1.17 retrieving revision 1.18 diff -u -d -r1.17 -r1.18 --- ExpectationMap_test.cpp 26 Nov 2005 17:57:48 -0000 1.17 +++ ExpectationMap_test.cpp 9 Dec 2005 18:56:20 -0000 1.18 @@ -29,21 +29,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationMap.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class ExpectationMap_test : public CppUnit::TestFixture +class ExpectationMap_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ExpectationMap_test ); CPPUNIT_TEST(test_chain); @@ -72,6 +71,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_expectNothing_revoked(); void test_expectNothing(); @@ -99,7 +100,14 @@ void fail_ifNoActual(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(ExpectationMap_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ExpectationMap_test); + +#endif // frameworks + void ExpectationMap_test::test_chain() @@ -356,4 +364,4 @@ } -#endif // HAVE_CPPUNIT + Index: CustomStub_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/CustomStub_test.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- CustomStub_test.cpp 15 Oct 2005 15:40:58 -0000 1.11 +++ CustomStub_test.cpp 9 Dec 2005 18:56:20 -0000 1.12 @@ -29,35 +29,43 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/stub/CustomStub.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class CustomStub_test : public CppUnit::TestFixture +class CustomStub_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( CustomStub_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(CustomStub_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (CustomStub_test); + +#endif // frameworks + template <typename R, // Returntype typename I> // Invocation @@ -85,4 +93,4 @@ } -#endif // HAVE_CPPUNIT + Index: VisitableMockObject_2_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/VisitableMockObject_2_void_test.cpp,v retrieving revision 1.21 retrieving revision 1.22 diff -u -d -r1.21 -r1.22 --- VisitableMockObject_2_void_test.cpp 28 Nov 2005 19:03:09 -0000 1.21 +++ VisitableMockObject_2_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.22 @@ -31,11 +31,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsEqual.h> #include <mockpp/constraint/IsNot.h> @@ -46,12 +42,15 @@ #include <mockpp/ExpectationValue.h> #include <mockpp/VisitableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> -class VisitableMockObject_2_void_test : public CppUnit::TestFixture +class VisitableMockObject_2_void_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( VisitableMockObject_2_void_test ); CPPUNIT_TEST(test_outbound); @@ -73,6 +72,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_outbound(); @@ -94,7 +95,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(VisitableMockObject_2_void_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (VisitableMockObject_2_void_test); + +#endif // frameworks + class MyVisitableMockObject_2_void : public mockpp::VisitableMockObject @@ -421,4 +429,4 @@ } -#endif // HAVE_CPPUNIT + Index: VisitableMockObject_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/VisitableMockObject_test.cpp,v retrieving revision 1.25 retrieving revision 1.26 diff -u -d -r1.25 -r1.26 --- VisitableMockObject_test.cpp 28 Nov 2005 19:03:09 -0000 1.25 +++ VisitableMockObject_test.cpp 9 Dec 2005 18:56:20 -0000 1.26 @@ -31,21 +31,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationValue.h> #include <mockpp/VisitableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> -class VisitableMockObject_test : public CppUnit::TestFixture +class VisitableMockObject_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( VisitableMockObject_test ); CPPUNIT_TEST(test_controller); @@ -70,6 +69,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_controller(); @@ -94,7 +95,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(VisitableMockObject_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (VisitableMockObject_test); + +#endif // frameworks + class MyVisitableMockObject : public mockpp::VisitableMockObject @@ -478,5 +486,5 @@ } -#endif // HAVE_CPPUNIT + Index: Assert_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/Assert_test.cpp,v retrieving revision 1.19 retrieving revision 1.20 diff -u -d -r1.19 -r1.20 --- Assert_test.cpp 28 Nov 2005 19:03:09 -0000 1.19 +++ Assert_test.cpp 9 Dec 2005 18:56:20 -0000 1.20 @@ -29,20 +29,19 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class Assert_test : public CppUnit::TestFixture +class Assert_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( Assert_test ); CPPUNIT_TEST(test_FalseTrue); @@ -70,6 +69,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void fail_fail(); void fail_failmsg(); @@ -95,7 +96,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(Assert_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (Assert_test); + +#endif // frameworks + void Assert_test::test_macros() @@ -815,5 +823,5 @@ } -#endif // HAVE_CPPUNIT + Index: IsLessOrEqual_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/IsLessOrEqual_test.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- IsLessOrEqual_test.cpp 15 Oct 2005 15:40:59 -0000 1.7 +++ IsLessOrEqual_test.cpp 9 Dec 2005 18:56:20 -0000 1.8 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsLessOrEqual.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class IsLessOrEqual_test : public CppUnit::TestFixture +class IsLessOrEqual_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( IsLessOrEqual_test ); CPPUNIT_TEST(test_invoke); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(IsLessOrEqual_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (IsLessOrEqual_test); + +#endif // frameworks + void IsLessOrEqual_test::test_describe() @@ -80,4 +88,4 @@ } -#endif // HAVE_CPPUNIT + Index: MixedMockObject_5_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/MixedMockObject_5_test.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- MixedMockObject_5_test.cpp 26 Nov 2005 17:57:48 -0000 1.7 +++ MixedMockObject_5_test.cpp 9 Dec 2005 18:56:20 -0000 1.8 @@ -31,11 +31,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationValue.h> #include <mockpp/MixedMockObject.h> @@ -49,17 +45,20 @@ #include "classes_ABCDE.h" -#include <cppunit/extensions/HelperMacros.h> //MOCKPP_TYPELESSSTUBADAPTER_PTI_IMPL(xx) -class MixedMockObject_5_test : public CppUnit::TestFixture +class MixedMockObject_5_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( MixedMockObject_5_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( MixedMockObject_5_test ); CPPUNIT_TEST(test_controller); CPPUNIT_TEST(test_chainer); @@ -67,6 +66,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_controller(); @@ -75,7 +76,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(MixedMockObject_5_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (MixedMockObject_5_test); + +#endif // frameworks + class MyMixedMockObject_5_Interface { @@ -225,4 +233,4 @@ } -#endif // HAVE_CPPUNIT + Index: ChainableMockObject_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockObject_test.cpp,v retrieving revision 1.24 retrieving revision 1.25 diff -u -d -r1.24 -r1.25 --- ChainableMockObject_test.cpp 27 Nov 2005 17:27:57 -0000 1.24 +++ ChainableMockObject_test.cpp 9 Dec 2005 18:56:20 -0000 1.25 @@ -31,28 +31,27 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ChainableMockObject.h> #include <mockpp/chaining/ChainingMockObjectSupport.h> #include <mockpp/chaining/Invocation.h> -#include <cppunit/extensions/HelperMacros.h> #include "MyBuilderNamespace.h" #include "MyMatchBuilder.h" -class ChainableMockObject_test : public CppUnit::TestFixture +class ChainableMockObject_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( ChainableMockObject_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( ChainableMockObject_test ); CPPUNIT_TEST(test_register); CPPUNIT_TEST(test_after_1); @@ -69,6 +68,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_after_1(); @@ -86,7 +87,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(ChainableMockObject_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ChainableMockObject_test); + +#endif // frameworks + class MyChainableMockObject : public mockpp::ChainableMockObject @@ -477,5 +485,5 @@ } -#endif // HAVE_CPPUNIT + Index: Invocation_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/Invocation_test.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- Invocation_test.cpp 26 Nov 2005 17:57:48 -0000 1.20 +++ Invocation_test.cpp 9 Dec 2005 18:56:20 -0000 1.21 @@ -31,22 +31,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/Invocation.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class Invocation_test : public CppUnit::TestFixture +class Invocation_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( Invocation_test ); CPPUNIT_TEST(test_equals0); @@ -64,6 +63,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_equals0(); @@ -81,7 +82,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(Invocation_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (Invocation_test); + +#endif // frameworks + typedef mockpp::Invocation0 Setter0Invocation; @@ -519,4 +527,4 @@ } -#endif // HAVE_CPPUNIT + Index: IsGreaterThan_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/IsGreaterThan_test.cpp,v retrieving revision 1.7 retrieving revision 1.8 diff -u -d -r1.7 -r1.8 --- IsGreaterThan_test.cpp 15 Oct 2005 15:40:59 -0000 1.7 +++ IsGreaterThan_test.cpp 9 Dec 2005 18:56:20 -0000 1.8 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsGreaterThan.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class IsGreaterThan_test : public CppUnit::TestFixture +class IsGreaterThan_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( IsGreaterThan_test ); CPPUNIT_TEST(test_describe); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(IsGreaterThan_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (IsGreaterThan_test); + +#endif // frameworks + void IsGreaterThan_test::test_describe() @@ -80,4 +88,4 @@ } -#endif // HAVE_CPPUNIT + Index: NoException_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/NoException_test.cpp,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- NoException_test.cpp 7 Dec 2005 19:48:12 -0000 1.1 +++ NoException_test.cpp 9 Dec 2005 18:56:20 -0000 1.2 @@ -29,32 +29,40 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" -#include <cppunit/extensions/HelperMacros.h> -class NoException_test : public CppUnit::TestFixture +class NoException_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( NoException_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(NoException_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (NoException_test); + +#endif // frameworks + void NoException_test::test_invoke() @@ -62,4 +70,4 @@ } -#endif // HAVE_CPPUNIT + Index: ChainableMockObject_4_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockObject_4_void_test.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- ChainableMockObject_4_void_test.cpp 27 Nov 2005 17:27:57 -0000 1.12 +++ ChainableMockObject_4_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.13 @@ -31,16 +31,11 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/mockpp_pti.h> #include <mockpp/ChainableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> #include <mockpp/chaining/ChainingMockObjectSupport.h> #include <mockpp/chaining/Invocation.h> @@ -48,17 +43,23 @@ #include <mockpp/constraint/OutBound.h> -class ChainableMockObject_4_void_test : public CppUnit::TestFixture +class ChainableMockObject_4_void_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( ChainableMockObject_4_void_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( ChainableMockObject_4_void_test ); CPPUNIT_TEST(test_outbound); CPPUNIT_TEST( test_parameter_4 ); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_outbound(); @@ -66,7 +67,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(ChainableMockObject_4_void_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ChainableMockObject_4_void_test); + +#endif // frameworks + typedef mockpp::Invocation4<unsigned, unsigned, unsigned, unsigned> mockpp_Invocation4_unsigned_unsigned_unsigned_unsigned; @@ -190,4 +198,4 @@ } -#endif // HAVE_CPPUNIT + Index: InvocationMockerBuilder_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/InvocationMockerBuilder_test.cpp,v retrieving revision 1.30 retrieving revision 1.31 diff -u -d -r1.30 -r1.31 --- InvocationMockerBuilder_test.cpp 18 Oct 2005 20:03:54 -0000 1.30 +++ InvocationMockerBuilder_test.cpp 9 Dec 2005 18:56:20 -0000 1.31 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/builder/InvocationMockerBuilder.h> #include <mockpp/builder/ArgumentsMatchBuilder.h> @@ -49,7 +45,6 @@ #include <mockpp/constraint/IsEqual.h> -#include <cppunit/extensions/HelperMacros.h> #include "classes_ABCDE.h" #include "MyBuilderNamespace.h" @@ -68,11 +63,15 @@ namespace { -class InvocationMockerBuilder_test : public CppUnit::TestFixture +class InvocationMockerBuilder_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( InvocationMockerBuilder_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( InvocationMockerBuilder_test ); CPPUNIT_TEST( test_instance0 ); CPPUNIT_TEST( test_instance5 ); @@ -81,6 +80,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_instance0(); @@ -90,7 +91,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION( InvocationMockerBuilder_test ); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION ( InvocationMockerBuilder_test ); + +#endif // frameworks + template <typename AMB> // ArgumentsMatchBuilder @@ -307,4 +315,4 @@ } // namespace -#endif // HAVE_CPPUNIT + Index: StringContains_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/StringContains_test.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- StringContains_test.cpp 26 Nov 2005 17:57:48 -0000 1.11 +++ StringContains_test.cpp 9 Dec 2005 18:56:20 -0000 1.12 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/StringContains.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class StringContains_test : public CppUnit::TestFixture +class StringContains_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( StringContains_test ); CPPUNIT_TEST(test_invoke); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(StringContains_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (StringContains_test); + +#endif // frameworks + void StringContains_test::test_describe() @@ -79,4 +87,4 @@ } -#endif // HAVE_CPPUNIT + Index: InvokeAtLeastOnceMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/InvokeAtLeastOnceMatcher_test.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- InvokeAtLeastOnceMatcher_test.cpp 27 Nov 2005 17:27:57 -0000 1.9 +++ InvokeAtLeastOnceMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.10 @@ -29,33 +29,41 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/InvokeAtLeastOnceMatcher.h> -#include <cppunit/extensions/HelperMacros.h> -class InvokeAtLeastOnceMatcher_test : public CppUnit::TestFixture +class InvokeAtLeastOnceMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( InvokeAtLeastOnceMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(InvokeAtLeastOnceMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (InvokeAtLeastOnceMatcher_test); + +#endif // frameworks + void InvokeAtLeastOnceMatcher_test::test_invoke() @@ -108,4 +116,4 @@ } -#endif // HAVE_CPPUNIT + Index: ExpectationSet_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ExpectationSet_test.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- ExpectationSet_test.cpp 13 Nov 2005 11:53:18 -0000 1.15 +++ ExpectationSet_test.cpp 9 Dec 2005 18:56:20 -0000 1.16 @@ -29,21 +29,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationSet.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class ExpectationSet_test : public CppUnit::TestFixture +class ExpectationSet_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ExpectationSet_test ); CPPUNIT_TEST(test_hasExpectations); @@ -68,6 +67,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_expectNothing(); void test_expectNothing_revoked(); @@ -91,7 +92,14 @@ void fail_ifNoActual(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(ExpectationSet_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ExpectationSet_test); + +#endif // frameworks + void ExpectationSet_test::test_chain() @@ -282,4 +290,4 @@ } -#endif // HAVE_CPPUNIT + Index: ChainableMockObject_1_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockObject_1_void_test.cpp,v retrieving revision 1.15 retrieving revision 1.16 diff -u -d -r1.15 -r1.16 --- ChainableMockObject_1_void_test.cpp 27 Nov 2005 17:27:57 -0000 1.15 +++ ChainableMockObject_1_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.16 @@ -31,16 +31,11 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/mockpp_pti.h> #include <mockpp/ChainableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> #include <mockpp/chaining/ChainingMockObjectSupport.h> #include <mockpp/chaining/Invocation.h> @@ -53,17 +48,23 @@ MOCKPP_PTI_IMPLEMENT(TheInvocation) -class ChainableMockObject_1_void_test : public CppUnit::TestFixture +class ChainableMockObject_1_void_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( ChainableMockObject_1_void_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( ChainableMockObject_1_void_test ); CPPUNIT_TEST(test_outbound); CPPUNIT_TEST( test_parameter_1 ); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_outbound(); @@ -72,7 +73,14 @@ -CPPUNIT_TEST_SUITE_REGISTRATION(ChainableMockObject_1_void_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ChainableMockObject_1_void_test); + +#endif // frameworks + class MyChainableMockObject_1_void : public mockpp::ChainableMockObject @@ -180,4 +188,4 @@ } -#endif // HAVE_CPPUNIT + Index: ChainableMockMethod_2_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockMethod_2_test.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- ChainableMockMethod_2_test.cpp 27 Nov 2005 17:27:57 -0000 1.10 +++ ChainableMockMethod_2_test.cpp 9 Dec 2005 18:56:20 -0000 1.11 @@ -31,11 +31,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/ChainableMockMethod.h> #include <mockpp/chaining/ChainableMockMethod0.h> @@ -52,22 +48,27 @@ #include "IncCounter.h" -#include <cppunit/extensions/HelperMacros.h> namespace { // anon -class ChainableMockMethod_2_test : public CppUnit::TestFixture +class ChainableMockMethod_2_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( ChainableMockMethod_2_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( ChainableMockMethod_2_test ); CPPUNIT_TEST( test_parameter_2 ); CPPUNIT_TEST( test_parameter_2v ); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_parameter_2(); @@ -75,7 +76,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(ChainableMockMethod_2_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ChainableMockMethod_2_test); + +#endif // frameworks + class MyChainableMockObject_2 : public mockpp::ChainableMockObject @@ -185,5 +193,5 @@ } // anon ns -#endif // HAVE_CPPUNIT + Index: InvokedAfterMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/InvokedAfterMatcher_test.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- InvokedAfterMatcher_test.cpp 27 Nov 2005 17:27:57 -0000 1.9 +++ InvokedAfterMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.10 @@ -29,33 +29,41 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/InvokedAfterMatcher.h> -#include <cppunit/extensions/HelperMacros.h> -class InvokedAfterMatcher_test : public CppUnit::TestFixture +class InvokedAfterMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( InvokedAfterMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(InvokedAfterMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (InvokedAfterMatcher_test); + +#endif // frameworks + void InvokedAfterMatcher_test::test_invoke() @@ -101,4 +109,4 @@ } -#endif // HAVE_CPPUNIT + Index: InvokeOnceMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/InvokeOnceMatcher_test.cpp,v retrieving revision 1.9 retrieving revision 1.10 diff -u -d -r1.9 -r1.10 --- InvokeOnceMatcher_test.cpp 27 Nov 2005 17:27:57 -0000 1.9 +++ InvokeOnceMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.10 @@ -29,33 +29,41 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/InvokeOnceMatcher.h> -#include <cppunit/extensions/HelperMacros.h> -class InvokeOnceMatcher_test : public CppUnit::TestFixture +class InvokeOnceMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( InvokeOnceMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(InvokeOnceMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (InvokeOnceMatcher_test); + +#endif // frameworks + void InvokeOnceMatcher_test::test_invoke() @@ -108,4 +116,4 @@ } -#endif // HAVE_CPPUNIT + Index: ChainableMockObject_3_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockObject_3_void_test.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- ChainableMockObject_3_void_test.cpp 27 Nov 2005 17:27:57 -0000 1.12 +++ ChainableMockObject_3_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.13 @@ -31,16 +31,11 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/mockpp_pti.h> #include <mockpp/ChainableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> #include <mockpp/chaining/ChainingMockObjectSupport.h> #include <mockpp/chaining/Invocation.h> @@ -48,17 +43,23 @@ #include <mockpp/constraint/OutBound.h> -class ChainableMockObject_3_void_test : public CppUnit::TestFixture +class ChainableMockObject_3_void_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: - CPPUNIT_TEST_SUITE( ChainableMockObject_3_void_test ); + #if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE( ChainableMockObject_3_void_test ); CPPUNIT_TEST(test_outbound); CPPUNIT_TEST( test_parameter_3 ); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_outbound(); @@ -66,7 +67,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(ChainableMockObject_3_void_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ChainableMockObject_3_void_test); + +#endif // frameworks + typedef mockpp::Invocation3<unsigned, unsigned, unsigned> mockpp_Invocation3_unsigned_unsigned_unsigned; @@ -186,4 +194,4 @@ } -#endif // HAVE_CPPUNIT + Index: VoidStub_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/VoidStub_test.cpp,v retrieving revision 1.11 retrieving revision 1.12 diff -u -d -r1.11 -r1.12 --- VoidStub_test.cpp 15 Oct 2005 15:40:59 -0000 1.11 +++ VoidStub_test.cpp 9 Dec 2005 18:56:20 -0000 1.12 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/stub/VoidStub.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class VoidStub_test : public CppUnit::TestFixture +class VoidStub_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( VoidStub_test ); CPPUNIT_TEST(test_describe); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(VoidStub_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (VoidStub_test); + +#endif // frameworks + void VoidStub_test::test_describe() @@ -81,4 +89,4 @@ } -#endif // HAVE_CPPUNIT + Index: ExpectationCounter_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ExpectationCounter_test.cpp,v retrieving revision 1.14 retrieving revision 1.15 diff -u -d -r1.14 -r1.15 --- ExpectationCounter_test.cpp 13 Nov 2005 11:53:18 -0000 1.14 +++ ExpectationCounter_test.cpp 9 Dec 2005 18:56:20 -0000 1.15 @@ -30,21 +30,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationCounter.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class ExpectationCounter_test : public CppUnit::TestFixture +class ExpectationCounter_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ExpectationCounter_test ); CPPUNIT_TEST(test_hasExpectations); @@ -66,6 +65,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_expectNothing(); void test_expectNothing_revoked(); @@ -89,7 +90,14 @@ void doActualVerify(mockpp::ExpectationCounter &ec); }; -CPPUNIT_TEST_SUITE_REGISTRATION(ExpectationCounter_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ExpectationCounter_test); + +#endif // frameworks + void ExpectationCounter_test::test_name() @@ -242,4 +250,4 @@ } -#endif // HAVE_CPPUNIT + Index: OutBound_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/OutBound_test.cpp,v retrieving revision 1.2 retrieving revision 1.3 diff -u -d -r1.2 -r1.3 --- OutBound_test.cpp 15 Oct 2005 15:40:59 -0000 1.2 +++ OutBound_test.cpp 9 Dec 2005 18:56:20 -0000 1.3 @@ -29,20 +29,19 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/OutBound.h> -#include <cppunit/extensions/HelperMacros.h> -class OutBound_test : public CppUnit::TestFixture +class OutBound_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( OutBound_test ); CPPUNIT_TEST(test_describe); @@ -50,6 +49,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); @@ -57,7 +58,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(OutBound_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (OutBound_test); + +#endif // frameworks + void OutBound_test::test_describe() @@ -82,4 +90,4 @@ } -#endif // HAVE_CPPUNIT + Index: ResponseVector_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ResponseVector_test.cpp,v retrieving revision 1.5 retrieving revision 1.6 diff -u -d -r1.5 -r1.6 --- ResponseVector_test.cpp 28 Nov 2005 19:03:09 -0000 1.5 +++ ResponseVector_test.cpp 9 Dec 2005 18:56:20 -0000 1.6 @@ -29,22 +29,21 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/VisitableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> -class ResponseVector_Test : public CppUnit::TestFixture +class ResponseVector_Test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ResponseVector_Test ); CPPUNIT_TEST(test_value); @@ -52,6 +51,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_value(); @@ -59,7 +60,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(ResponseVector_Test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ResponseVector_Test); + +#endif // frameworks + void ResponseVector_Test::test_value() @@ -152,5 +160,5 @@ } -#endif // HAVE_CPPUNIT + Index: ExpectationConglomeration_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ExpectationConglomeration_test.cpp,v retrieving revision 1.13 retrieving revision 1.14 diff -u -d -r1.13 -r1.14 --- ExpectationConglomeration_test.cpp 13 Nov 2005 11:53:18 -0000 1.13 +++ ExpectationConglomeration_test.cpp 9 Dec 2005 18:56:20 -0000 1.14 @@ -29,21 +29,20 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/ExpectationConglomeration.h> #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class ExpectationConglomeration_test : public CppUnit::TestFixture +class ExpectationConglomeration_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( ExpectationConglomeration_test ); CPPUNIT_TEST(test_hasExpectations); @@ -69,6 +68,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_expectNothing(); void test_expectNothing_revoked(); @@ -93,7 +94,14 @@ void fail_ifNoActual(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(ExpectationConglomeration_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (ExpectationConglomeration_test); + +#endif // frameworks + void ExpectationConglomeration_test::test_chain() @@ -312,4 +320,4 @@ } -#endif // HAVE_CPPUNIT + Index: NoArgumentsMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/NoArgumentsMatcher_test.cpp,v retrieving revision 1.10 retrieving revision 1.11 diff -u -d -r1.10 -r1.11 --- NoArgumentsMatcher_test.cpp 15 Oct 2005 15:40:59 -0000 1.10 +++ NoArgumentsMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.11 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/NoArgumentsMatcher.h> @@ -41,25 +37,37 @@ #include <mockpp/compat/Assert.h> -#include <cppunit/extensions/HelperMacros.h> -class NoArgumentsMatcher_test : public CppUnit::TestFixture +class NoArgumentsMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE(NoArgumentsMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(NoArgumentsMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (NoArgumentsMatcher_test); + +#endif // frameworks + void NoArgumentsMatcher_test::test_invoke() @@ -83,4 +91,4 @@ } -#endif // HAVE_CPPUNIT + Index: InvokeAtMostMatcher_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/InvokeAtMostMatcher_test.cpp,v retrieving revision 1.8 retrieving revision 1.9 diff -u -d -r1.8 -r1.9 --- InvokeAtMostMatcher_test.cpp 27 Nov 2005 17:27:57 -0000 1.8 +++ InvokeAtMostMatcher_test.cpp 9 Dec 2005 18:56:20 -0000 1.9 @@ -29,33 +29,41 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/matcher/InvokeAtMostMatcher.h> -#include <cppunit/extensions/HelperMacros.h> -class InvokeAtMostMatcher_test : public CppUnit::TestFixture +class InvokeAtMostMatcher_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( InvokeAtMostMatcher_test ); CPPUNIT_TEST(test_invoke); CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_invoke(); }; -CPPUNIT_TEST_SUITE_REGISTRATION(InvokeAtMostMatcher_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (InvokeAtMostMatcher_test); + +#endif // frameworks + void InvokeAtMostMatcher_test::test_invoke() @@ -110,4 +118,4 @@ } -#endif // HAVE_CPPUNIT + Index: VisitableMockObject_4_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/VisitableMockObject_4_test.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- VisitableMockObject_4_test.cpp 28 Nov 2005 19:03:09 -0000 1.20 +++ VisitableMockObject_4_test.cpp 9 Dec 2005 18:56:20 -0000 1.21 @@ -31,11 +31,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/ChainingMockObjectSupport.h> @@ -46,12 +42,15 @@ #include <mockpp/VisitableMockObject.h> #include <mockpp/util/AssertMo.h> -#include <cppunit/extensions/HelperMacros.h> -class VisitableMockObject_4_test : public CppUnit::TestFixture +class VisitableMockObject_4_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( VisitableMockObject_4_test ); CPPUNIT_TEST(test_controller); @@ -80,6 +79,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_controller(); @@ -108,7 +109,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(VisitableMockObject_4_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (VisitableMockObject_4_test); + +#endif // frameworks + class MyVisitableMockObject_4 : public mockpp::VisitableMockObject @@ -695,4 +703,4 @@ } -#endif // HAVE_CPPUNIT + Index: VisitableMockObject_3_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/VisitableMockObject_3_void_test.cpp,v retrieving revision 1.20 retrieving revision 1.21 diff -u -d -r1.20 -r1.21 --- VisitableMockObject_3_void_test.cpp 28 Nov 2005 19:03:09 -0000 1.20 +++ VisitableMockObject_3_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.21 @@ -31,11 +31,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/constraint/IsEqual.h> #include <mockpp/constraint/IsNot.h> @@ -46,12 +42,15 @@ #include <mockpp/ExpectationValue.h> #include <mockpp/VisitableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> -class VisitableMockObject_3_void_test : public CppUnit::TestFixture +class VisitableMockObject_3_void_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( VisitableMockObject_3_void_test ); CPPUNIT_TEST(test_outbound); @@ -73,6 +72,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_outbound(); @@ -94,7 +95,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(VisitableMockObject_3_void_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (VisitableMockObject_3_void_test); + +#endif // frameworks + class MyVisitableMockObject_3_void : public mockpp::VisitableMockObject @@ -438,4 +446,4 @@ } -#endif // HAVE_CPPUNIT + Index: StubSequence_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/StubSequence_test.cpp,v retrieving revision 1.16 retrieving revision 1.17 diff -u -d -r1.16 -r1.17 --- StubSequence_test.cpp 27 Nov 2005 17:27:57 -0000 1.16 +++ StubSequence_test.cpp 9 Dec 2005 18:56:20 -0000 1.17 @@ -29,11 +29,7 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include MOCKPP_VECTOR_H @@ -43,12 +39,15 @@ #include <mockpp/chaining/ChainingMockObjectSupport.h> -#include <cppunit/extensions/HelperMacros.h> -class StubSequence_test : public CppUnit::TestFixture +class StubSequence_test MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK { public: +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + CPPUNIT_TEST_SUITE( StubSequence_test ); CPPUNIT_TEST(test_invoke); @@ -56,6 +55,8 @@ CPPUNIT_TEST_SUITE_END(); +#endif + public: void test_describe(); @@ -63,7 +64,14 @@ }; -CPPUNIT_TEST_SUITE_REGISTRATION(StubSequence_test); +#if defined (HAVE_CXXTEST) + +#elif defined(HAVE_CPPUNIT) + +CPPUNIT_TEST_SUITE_REGISTRATION (StubSequence_test); + +#endif // frameworks + void StubSequence_test::test_describe() @@ -124,4 +132,4 @@ } -#endif // HAVE_CPPUNIT + Index: SelectFramework.h =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/SelectFramework.h,v retrieving revision 1.1 retrieving revision 1.2 diff -u -d -r1.1 -r1.2 --- SelectFramework.h 9 Dec 2005 15:55:36 -0000 1.1 +++ SelectFramework.h 9 Dec 2005 18:56:20 -0000 1.2 @@ -27,6 +27,9 @@ * ***************************************************************************/ +#ifndef MOCKPP_SELECTFRAMEWORK_H +#define MOCKPP_SELECTFRAMEWORK_H + #if defined(HAVE_CXXTEST) # define MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK /**/ @@ -41,4 +44,6 @@ # pragma message ("No unittest framework available at compile time") # define MOCKPP_DERIVE_PUBLIC_UNITFRAMEWORK /**/ -#endif // HAVE_CPPUNIT +#endif // frameworks + +#endif // MOCKPP_SELECTFRAMEWORK_H Index: ChainableMockObject_2_void_test.cpp =================================================================== RCS file: /cvsroot/mockpp/mockpp/mockpp/tests/ChainableMockObject_2_void_test.cpp,v retrieving revision 1.12 retrieving revision 1.13 diff -u -d -r1.12 -r1.13 --- ChainableMockObject_2_void_test.cpp 27 Nov 2005 17:27:57 -0000 1.12 +++ ChainableMockObject_2_void_test.cpp 9 Dec 2005 18:56:20 -0000 1.13 @@ -31,16 +31,11 @@ #include <mockpp/mockpp.h> // always first -#ifndef HAVE_CPPUNIT - -# warning CppUnit not available at compile time - -#else +#include "SelectFramework.h" #include <mockpp/chaining/mockpp_pti.h> #include <mockpp/ChainableMockObject.h> -#include <cppunit/extensions/HelperMacros.h> #include <mockpp/chaining/ChainingMockObjectSupport.h> #include <mockpp/chaining/Invocation.h> @@ -48,17 +43,23 ... [truncated message content] |