From f26e7b0d97858a49f59fd9a8cdabec184660af8e Mon Sep 17 00:00:00 2001 From: Nick Bolton Date: Tue, 10 Jul 2012 13:55:05 +0000 Subject: [PATCH] fixed unit tests (log not initialized) --- src/test/integtests/Main.cpp | 2 +- src/test/unittests/Main.cpp | 6 +++++- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/src/test/integtests/Main.cpp b/src/test/integtests/Main.cpp index 456bd01b..f1f6ebac 100644 --- a/src/test/integtests/Main.cpp +++ b/src/test/integtests/Main.cpp @@ -44,6 +44,7 @@ main(int argc, char **argv) arch.init(); CLog log; + log.setFilter(kDEBUG2); string lockFile; for (int i = 0; i < argc; i++) { @@ -56,7 +57,6 @@ main(int argc, char **argv) lock(lockFile); } - CLOG->setFilter(kDEBUG2); testing::InitGoogleTest(&argc, argv); diff --git a/src/test/unittests/Main.cpp b/src/test/unittests/Main.cpp index eafc8155..f1932827 100644 --- a/src/test/unittests/Main.cpp +++ b/src/test/unittests/Main.cpp @@ -31,7 +31,11 @@ main(int argc, char **argv) CArchMiscWindows::setInstanceWin32(GetModuleHandle(NULL)); #endif - CLOG->setFilter(kDEBUG2); + CArch arch; + arch.init(); + + CLog log; + log.setFilter(kDEBUG2); testing::InitGoogleTest(&argc, argv);