summaryrefslogtreecommitdiffstats
path: root/src/include/usr/cxxtest
diff options
context:
space:
mode:
authorMark Wenning <wenning@us.ibm.com>2011-05-18 15:52:46 -0500
committerA. Patrick Williams III <iawillia@us.ibm.com>2011-06-01 14:07:35 -0500
commit8509613766f5b1074f89589e653bcb8a4cec2ac0 (patch)
treee5445f93b2bb1c1a9741b737f217b0385e0e5f96 /src/include/usr/cxxtest
parent329be941b1056a3b2e68fcfdf1bc4a9cd5335c84 (diff)
downloadtalos-hostboot-8509613766f5b1074f89589e653bcb8a4cec2ac0.tar.gz
talos-hostboot-8509613766f5b1074f89589e653bcb8a4cec2ac0.zip
CxxTest logs messages to trace buffer
- mark globals with g_ - thread safety - remove more tabs. - Add globals and accessors to track totaltests, failedtests, warnings, tracecalls. - Modify cxxtestgen.pl to add reportTotalTests() call - uncommented printk's in TestSuite.C - cxxtestgen.pl just prints out the test suite - exampletest.H has more descriptive test names, forces a FAIL, WARN, and TRACE - add a printk() to cxxtest module so that we know it ran. Change-Id: I3ff25b228f17371b6f84bdb16309015818867266 Reviewed-on: http://gfw160.austin.ibm.com:8080/gerrit/90 Tested-by: Jenkins Server Reviewed-by: A. Patrick Williams III <iawillia@us.ibm.com>
Diffstat (limited to 'src/include/usr/cxxtest')
-rwxr-xr-xsrc/include/usr/cxxtest/TestSuite.H14
1 files changed, 13 insertions, 1 deletions
diff --git a/src/include/usr/cxxtest/TestSuite.H b/src/include/usr/cxxtest/TestSuite.H
index 3cba6eeac..bd152196b 100755
--- a/src/include/usr/cxxtest/TestSuite.H
+++ b/src/include/usr/cxxtest/TestSuite.H
@@ -3,6 +3,11 @@
#ifndef __cxxtest__TestSuite_h__
#define __cxxtest__TestSuite_h__
+/******************************************************************************/
+// Includes
+/******************************************************************************/
+#include <stdint.h>
+
//
// class TestSuite is the base class for all test suites.
// To define a test suite, derive from this class and add
@@ -18,7 +23,7 @@ namespace CxxTest
virtual void setUp();
virtual void tearDown();
};
-
+
class AbortTest {};
void doTrace( const char *file, unsigned line, const char *message );
@@ -27,6 +32,13 @@ namespace CxxTest
void doFailAssert( const char *file, unsigned line, const char *expression, const char *message );
+ void reportTotalTests( const char *suitename, uint64_t numtests );
+
+ // $$ these should be set up as readonly accessors
+ uint64_t getTotalTests(void);
+ uint64_t getFailedTests(void);
+ uint64_t getWarnings(void);
+ uint64_t getTraceCalls(void);
# define _TS_TRY
# define ___TSM_CATCH(f,l,m)
OpenPOWER on IntegriCloud