7 #include <UnitTest++.h> 21 CHECK_THROW(EncodeXiaData(
XiaData(),
R30474, 250), invalid_argument);
24 CHECK_THROW(EncodeXiaData(
XiaData(),
UNKNOWN, 250), invalid_argument);
27 CHECK_THROW(EncodeXiaData(
XiaData(),
R30474, 2500), invalid_argument);
52 data.
SetTrace(vector<unsigned int>());
63 int main(
int argv,
char *argc[]) {
64 return (UnitTest::RunAllTests());
std::vector< unsigned int > header_vec_w_qdc
void SetEventTimeLow(const unsigned int &a)
Sets the lower 32 bits of the event time.
void SetCrateNumber(const unsigned int &a)
Sets the crate number.
static const unsigned int ts_low
static const unsigned int crateId
void SetSlotNumber(const unsigned int &a)
Sets the slot number.
static const std::vector< unsigned int > trace
void SetChannelNumber(const unsigned int &a)
Sets the channel number.
static const unsigned int channelNumber
std::vector< unsigned int > header_vec
std::vector< unsigned int > header_vec_w_qdc_n_trc
void SetTrace(const std::vector< unsigned int > &a)
Sets the trace recorded on board.
static const std::vector< unsigned int > qdc
void SetQdc(const std::vector< unsigned int > &a)
Sets the QDCs that were calculated on-board.
Header containing namespaced enumerations that are useful to different parts of the software...
void SetEnergy(const double &a)
Sets the energy calculated on-board.
This header provides sample data that can be used by Unit Tests to ensure proper functionality.
static const unsigned int slotId
int main(int argv, char *argc[])
Class that handles encoding Pixie-16 list mode data from a XiaData class.
TEST_FIXTURE(XiaListModeDataEncoder, TestEncodingThrows)
std::vector< unsigned int > header_vec_w_trc
static const unsigned int ts_high
static const unsigned int energy
void SetEventTimeHigh(const unsigned int &a)
Sets the upper 16 bits of the event time.