Fix unit test assertion failure error message (was printing the value instead of the expression itself)
authorGustavo J. A. M. Carneiro <gjc@inescporto.pt>
Mon, 09 Jul 2007 14:31:52 +0100
changeset 920 f04132bd679b
parent 919 a9c7effce441
child 921 37b54ed96b09
Fix unit test assertion failure error message (was printing the value instead of the expression itself)
src/core/test.h
--- a/src/core/test.h	Sun Jul 08 12:24:22 2007 +0100
+++ b/src/core/test.h	Mon Jul 09 14:31:52 2007 +0100
@@ -130,8 +130,8 @@
     if (!(assertion))                                   \
       {                                                 \
         Failure () << __FILE__ << ":" <<__LINE__        \
-                   << ": assertion `" << (assertion)    \
-                   << "'failed." << std::endl;          \
+                   << ": assertion `" << #assertion     \
+                   << "' failed." << std::endl;         \
         result = false;                                 \
       }