1.00.17
C++ library of Revenue Management and Optimisation classes and functions
Toggle main menu visibility
Loading...
Searching...
No Matches
ForecasterTestSuite.cpp
Go to the documentation of this file.
1
5
// //////////////////////////////////////////////////////////////////////
6
// Import section
7
// //////////////////////////////////////////////////////////////////////
8
// STL
9
#include <sstream>
10
#include <fstream>
11
#include <string>
12
#include <vector>
13
#include <cmath>
14
// Boost Unit Test Framework (UTF)
15
#define BOOST_TEST_DYN_LINK
16
#define BOOST_TEST_MAIN
17
#define BOOST_TEST_MODULE ForecasterTestSuite
18
#include <boost/test/unit_test.hpp>
19
// StdAir
20
#include <stdair/basic/BasLogParams.hpp>
21
#include <stdair/basic/BasDBParams.hpp>
22
#include <stdair/basic/BasFileMgr.hpp>
23
#include <stdair/service/Logger.hpp>
24
// RMOL
25
#include <
rmol/RMOL_Service.hpp
>
26
27
namespace
boost_utf = boost::unit_test;
28
29
// (Boost) Unit Test XML Report
30
std::ofstream utfReportStream (
"ForecasterTestSuite_utfresults.xml"
);
31
35
struct
UnitTestConfig {
37
UnitTestConfig() {
38
boost_utf::unit_test_log.set_stream (utfReportStream);
39
#if defined(BOOST_VERSION) && BOOST_VERSION >= 105900
40
boost_utf::unit_test_log.set_format (boost_utf::OF_XML);
41
#else
// BOOST_VERSION
42
boost_utf::unit_test_log.set_format (boost_utf::XML);
43
#endif
// BOOST_VERSION
44
boost_utf::unit_test_log.set_threshold_level (boost_utf::log_test_units);
45
//boost_utf::unit_test_log.set_threshold_level (boost_utf::log_successful_tests);
46
}
47
49
~UnitTestConfig() {
50
}
51
};
52
53
54
// /////////////// Main: Unit Test Suite //////////////
55
56
// Set the UTF configuration (re-direct the output to a specific file)
57
BOOST_GLOBAL_FIXTURE (UnitTestConfig);
58
63
BOOST_AUTO_TEST_SUITE (master_test_suite)
64
65
68
BOOST_AUTO_TEST_CASE (rmol_forecaster_q_forecasting) {
69
const
bool
lTestFlag =
true
;
//testForecasterHelper(0);
70
BOOST_CHECK_EQUAL (lTestFlag,
true
);
71
BOOST_CHECK_MESSAGE (lTestFlag ==
true
,
72
"The test has failed. Please see the log file for "
73
<<
"more details"
);
74
}
75
76
// End the test suite
77
BOOST_AUTO_TEST_SUITE_END()
78
79
RMOL_Service.hpp
Generated for RMOL by
1.17.0