From 6c3b4a051f93dee868fd91d5b8f53b7125f68d26 Mon Sep 17 00:00:00 2001 From: Tyler Dauwalder Date: Mon, 15 Jul 2002 06:50:13 +0000 Subject: [PATCH] Added code to honor BTestShell::Verbosity() levels when outputting git-svn-id: file:///srv/svn/repos/haiku/trunk/current@232 a95241bf-73f2-0310-859d-f6bbb57e9c96 --- src/tools/cppunit/TestCase.cpp | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/tools/cppunit/TestCase.cpp b/src/tools/cppunit/TestCase.cpp index 278c82edf8..f1cd19449d 100644 --- a/src/tools/cppunit/TestCase.cpp +++ b/src/tools/cppunit/TestCase.cpp @@ -1,4 +1,5 @@ #include +#include #include #include @@ -16,13 +17,18 @@ BTestCase::tearDown() { void BTestCase::NextSubTest() { - printf("[%ld]", fSubTestNum++); - fflush(stdout); + BTestShell *shell = BTestShell::Shell(); + if (shell && shell->BeVerbose()) { + printf("[%ld]", fSubTestNum++); + fflush(stdout); + } } void BTestCase::NextSubTestBlock() { - printf("\n"); + BTestShell *shell = BTestShell::Shell(); + if (shell && shell->BeVerbose()) + printf("\n"); } /*! To return to the last saved working directory, call RestoreCWD(). */