diff options
author | dan miller | 2007-10-19 05:22:23 +0000 |
---|---|---|
committer | dan miller | 2007-10-19 05:22:23 +0000 |
commit | 1ec410ecd725f5a3ccb2d2fc16f48730d9d9fe43 (patch) | |
tree | 51bcae7a1b8381a6bf6fd8025a7de1e30fe0045d /libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp | |
parent | one more for the gipper (diff) | |
download | opensim-SC_OLD-1ec410ecd725f5a3ccb2d2fc16f48730d9d9fe43.zip opensim-SC_OLD-1ec410ecd725f5a3ccb2d2fc16f48730d9d9fe43.tar.gz opensim-SC_OLD-1ec410ecd725f5a3ccb2d2fc16f48730d9d9fe43.tar.bz2 opensim-SC_OLD-1ec410ecd725f5a3ccb2d2fc16f48730d9d9fe43.tar.xz |
trying to fix my screwup, please hold on
Diffstat (limited to 'libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp')
-rw-r--r-- | libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp | 56 |
1 files changed, 0 insertions, 56 deletions
diff --git a/libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp b/libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp deleted file mode 100644 index 51db141..0000000 --- a/libraries/ode-0.9/tests/CppTestHarness/TestRunner.cpp +++ /dev/null | |||
@@ -1,56 +0,0 @@ | |||
1 | #include "TestRunner.h" | ||
2 | #include "TestLauncher.h" | ||
3 | #include "TestResults.h" | ||
4 | #include "Test.h" | ||
5 | |||
6 | #include "PrintfTestReporter.h" | ||
7 | |||
8 | namespace CppTestHarness | ||
9 | { | ||
10 | |||
11 | TestRunner::TestRunner() | ||
12 | : m_testLauncherListHead(TestLauncher::GetHeadAddr()) | ||
13 | , m_testReporter(&m_defaultTestReporter) | ||
14 | { | ||
15 | } | ||
16 | |||
17 | TestRunner::~TestRunner() | ||
18 | { | ||
19 | } | ||
20 | |||
21 | void TestRunner::SetTestLauncherListHead(TestLauncher** listHead) | ||
22 | { | ||
23 | m_testLauncherListHead = listHead; | ||
24 | } | ||
25 | |||
26 | void TestRunner::SetTestReporter(TestReporter* testReporter) | ||
27 | { | ||
28 | m_testReporter = testReporter; | ||
29 | } | ||
30 | |||
31 | int TestRunner::RunAllTests() | ||
32 | { | ||
33 | int failureCount = 0; | ||
34 | |||
35 | int testCount = 0; | ||
36 | TestLauncher const* curLauncher = *m_testLauncherListHead; | ||
37 | while (curLauncher) | ||
38 | { | ||
39 | ++testCount; | ||
40 | |||
41 | TestResults result(*m_testReporter); | ||
42 | curLauncher->Launch(result); | ||
43 | |||
44 | if (result.Failed()) | ||
45 | ++failureCount; | ||
46 | |||
47 | curLauncher = curLauncher->GetNext(); | ||
48 | } | ||
49 | |||
50 | m_testReporter->ReportSummary(testCount, failureCount); | ||
51 | |||
52 | return failureCount; | ||
53 | } | ||
54 | |||
55 | } | ||
56 | |||