23 const string myname =
"test_RunData: ";
25 cout << myname <<
"NDEBUG must be off." <<
endl;
28 string line =
"-----------------------------";
30 cout << myname << line <<
endl;
31 cout << myname <<
"Creating bad data." <<
endl;
38 cout << myname << line <<
endl;
39 cout << myname <<
"Make data good." <<
endl;
42 assert( dat.
run() == 123 );
43 cout << myname <<
"Add cryostat." <<
endl;
47 assert( dat.
cryostat() ==
"coldbox" );
48 cout << myname <<
"Add APAs." <<
endl;
53 assert( dat.
apas().size() == 2 );
54 assert( dat.
apas() == myapas );
55 cout << myname <<
"Add gain." <<
endl;
60 cout << myname <<
"Add shaping." <<
endl;
65 cout << myname <<
"Add leakage." <<
endl;
70 cout << myname <<
"Add HV frac." <<
endl;
75 cout << myname <<
"Add pulser amplitude" <<
endl;
80 cout << myname <<
"Add pulser period" <<
endl;
88 cout << myname << line <<
endl;
89 cout << myname <<
"Done." <<
endl;
96 bool useExistingFcl =
false;
100 cout <<
"Usage: " << argv[0] <<
" [ARG]" <<
endl;
101 cout <<
" If ARG = true, existing FCL file is used." <<
endl;
104 useExistingFcl = sarg ==
"true" || sarg ==
"1";
bool havePulserPeriod() const
void setApas(const IndexVector &val)
Index pulserAmplitude() const
const IndexVector & apas() const
int main(int argc, char *argv[])
int test_RunData(bool useExistingFcl=false)
Index pulserPeriod() const
std::vector< Index > IndexVector
bool haveCryostat() const
void setHvfrac(float val)
void setLeakage(float val)
void line(double t, double *p, double &x, double &y, double &z)
void setCryostat(Name val)
void setPulserAmplitude(Index val)
void setShaping(float val)
void setPulserPeriod(Index val)
QTextStream & endl(QTextStream &s)
bool havePulserAmplitude() const