15 #define BOOST_TEST_DYN_LINK
16 #define BOOST_TEST_MAIN
17 #define BOOST_TEST_MODULE IndexBuildingTestSuite
18 #include <boost/test/unit_test.hpp>
23 #include <opentrep/config/opentrep-paths.hpp>
25 namespace boost_utf = boost::unit_test;
28 std::ofstream
utfReportStream (
"IndexBuildingTestSuite_utfresults.xml");
37 boost_utf::unit_test_log.set_format (boost_utf::XML);
38 boost_utf::unit_test_log.set_threshold_level (boost_utf::log_test_units);
52 const std::string K_POR_FILEPATH (OPENTREP_POR_DATA_DIR
53 "/test_ori_por_public.csv");
63 const std::string
X_SQLITE_DB_FP (
"/tmp/opentrep/test_traveldb/ori_por_public.csv");
72 BOOST_AUTO_TEST_SUITE (master_test_suite)
80 std::string lLogFilename (
"IndexBuildingTestSuite.log");
83 std::ofstream logOutputFile;
85 logOutputFile.open (lLogFilename.c_str());
86 logOutputFile.clear();
101 opentrepService.buildSearchIndex();
103 BOOST_CHECK_MESSAGE (nbOfEntries == 9,
104 "The Xapian index ('" << lTravelDBFilePath
105 <<
"') contains " << nbOfEntries
106 <<
" entries, where as 9 are expected.");
109 logOutputFile.close();
113 BOOST_AUTO_TEST_SUITE_END()
const std::string X_XAPIAN_DB_FP(OPENTREP::DEFAULT_OPENTREP_XAPIAN_DB_FILEPATH)
unsigned int NbOfDBEntries_T
Interface for the OPENTREP Services.
std::list< Word_T > WordList_T
BOOST_GLOBAL_FIXTURE(UnitTestConfig)
BOOST_AUTO_TEST_CASE(partition_small_string)
std::list< Location > LocationList_T
std::ofstream utfReportStream("PartitionTestSuite_utfresults.xml")
const std::string X_SQLITE_DB_FP(OPENTREP::DEFAULT_OPENTREP_SQLITE_DB_FILEPATH)