12#define BOOST_TEST_MODULE Test EMCAL Reconstruction
13#define BOOST_TEST_MAIN
14#define BOOST_TEST_DYN_LINK
15#include <boost/test/unit_test.hpp>
32 std::array<std::string, 8> errornames = {{
"PageNotFound",
39 "TrailerIncomplete"}},
40 errortitles = {{
"Page not found",
47 "Trailer incomplete"}},
48 errordescriptions = {{
"Page with requested index not found",
49 "RDH of page cannot be decoded",
50 "Payload of page cannot be decoded",
51 "Access to header not belonging to requested superpage",
52 "Page decoding starting outside payload size",
53 "Access to payload not belonging to requested superpage",
54 "Inconsistent trailer in memory",
55 "Incomplete trailer"}};
73 for (
unsigned int errtype = 0; errtype < 7; errtype++) {
75 for (
unsigned int feeID = 0; feeID < 40; feeID++) {
77 return test.getErrorType() == errtypeval &&
test.getFECID() == feeID;
79 BOOST_CHECK_EXCEPTION(
testThrow(errtypeval, feeID),
Error handling of the raw reader.
static const char * getErrorCodeDescription(ErrorType_t errortype)
Get description of error type.
static constexpr int getNumberOfErrorTypes()
Get the number of error codes.
static const char * getErrorCodeTitles(ErrorType_t errortype)
Get title of error type.
static const char * getErrorCodeNames(ErrorType_t errortype)
Get name of error type.
ErrorType_t
Codes for different error types.
@ TRAILER_INCOMPLETE
Incomplete trailer words (i.e. registers)
@ HEADER_DECODING
Header cannot be decoded (format incorrect)
@ TRAILER_DECODING
Inconsistent trailer in memory (several trailer words missing the trailer marker)
@ PAGE_NOTFOUND
Page was not found (page index outside range)
@ HEADER_INVALID
Header in memory not belonging to requested superpage.
@ PAGE_START_INVALID
Page position starting outside payload size.
@ PAYLOAD_DECODING
Payload cannot be decoded (format incorrect)
@ PAYLOAD_INVALID
Payload in memory not belonging to requested superpage.
static int ErrorTypeToInt(RawDecodingError::ErrorType_t errortype)
Convert error type to error code number.
static ErrorType_t intToErrorType(unsigned int errortype)
BOOST_AUTO_TEST_CASE(asynch_schedule_test)
void testThrow(AltroDecoderError::ErrorType_t errortype)
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
FIXME: do not use data model tables.
BOOST_CHECK_EQUAL(triggersD.size(), triggers.size())