From 1ac2cc4288e82bfa57f0a1ac92d9dbe77df5e2c1 Mon Sep 17 00:00:00 2001 From: Emmanuel Milou <emmanuel.milou@savoirfairelinux.com> Date: Thu, 7 Apr 2011 17:43:20 -0400 Subject: [PATCH] [#5514] Restore test ni historytest suite --- sflphone-common/test/historytest.cpp | 9 ++++----- sflphone-common/test/historytest.h | 2 +- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/sflphone-common/test/historytest.cpp b/sflphone-common/test/historytest.cpp index ed84082219..76f58eb342 100644 --- a/sflphone-common/test/historytest.cpp +++ b/sflphone-common/test/historytest.cpp @@ -45,7 +45,7 @@ void HistoryTest::setUp() history = new HistoryManager(); } -/* + void HistoryTest::test_create_history_path() { _debug ("-------------------- HistoryTest::test_create_history_path --------------------\n"); @@ -55,14 +55,13 @@ void HistoryTest::test_create_history_path() std::string path; cpath = getenv ("XDG_DATA_HOME"); - (cpath != NULL) ? path = std::string (cpath) : path = std::string (HOMEDIR) - + "/.local/share/sflphone/history"; + (cpath != NULL) ? path = std::string (cpath) : path = std::string ("/") + HISTORY_SAMPLE; - result = history->create_history_path(); + result = history->create_history_path(path); CPPUNIT_ASSERT (result == 0); CPPUNIT_ASSERT (!history->is_loaded ()); CPPUNIT_ASSERT (history->_history_path == path); -}*/ +} void HistoryTest::test_load_history_from_file() { diff --git a/sflphone-common/test/historytest.h b/sflphone-common/test/historytest.h index 96526449ff..fac450afdf 100644 --- a/sflphone-common/test/historytest.h +++ b/sflphone-common/test/historytest.h @@ -53,7 +53,7 @@ class HistoryTest : public CppUnit::TestCase { * Use cppunit library macros to add unit test the factory */ CPPUNIT_TEST_SUITE (HistoryTest); - // CPPUNIT_TEST (test_create_history_path); + CPPUNIT_TEST (test_create_history_path); CPPUNIT_TEST (test_save_history_items_map); CPPUNIT_TEST (test_load_history_from_file); CPPUNIT_TEST (test_load_history_items_map); -- GitLab