activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r741301 - /activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp
Date Thu, 05 Feb 2009 21:33:28 GMT
Author: tabish
Date: Thu Feb  5 21:33:28 2009
New Revision: 741301

URL: http://svn.apache.org/viewvc?rev=741301&view=rev
Log:
Add more tests

Modified:
    activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp

Modified: activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp
URL: http://svn.apache.org/viewvc/activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp?rev=741301&r1=741300&r2=741301&view=diff
==============================================================================
--- activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp (original)
+++ activemq/activemq-cpp/trunk/src/test/decaf/lang/PointerTest.cpp Thu Feb  5 21:33:28 2009
@@ -94,10 +94,13 @@
     // Test Null Initialize
     Pointer<TestClassA> nullPointer;
     CPPUNIT_ASSERT( nullPointer.get() == NULL );
+    CPPUNIT_ASSERT( nullPointer == NULL );
+    CPPUNIT_ASSERT_NO_THROW( nullPointer.reset( NULL ) );
 
     // Test Value Constructor
     Pointer<TestClassA> pointer( thePointer );
     CPPUNIT_ASSERT( pointer.get() == thePointer );
+    CPPUNIT_ASSERT( pointer.get() != NULL );
 
     // Test Copy Constructor
     Pointer<TestClassA> ctorCopy( pointer );
@@ -122,6 +125,7 @@
         Pointer<ExceptionThrowingClass> ex( new ExceptionThrowingClass() );
         CPPUNIT_FAIL( "Should Have Thrown." );
     } catch(...) {}
+
 }
 
 ////////////////////////////////////////////////////////////////////////////////
@@ -195,10 +199,12 @@
 
     {
         Pointer<TestClassA> copy = ReturnByValue();
+        CPPUNIT_ASSERT( copy.get() != NULL );
     }
 
     {
         Pointer<TestClassA> copy = ReturnByConstReference();
+        CPPUNIT_ASSERT( copy.get() != NULL );
     }
 
     ReturnByConstReference();



Mime
View raw message