52 const string myname =
"test_VDColdboxChannelGroups: ";
54 cout << myname <<
"NDEBUG must be off." <<
endl;
57 string line =
"-----------------------------";
59 cout << myname << line <<
endl;
60 string fclfile =
"test_VDColdboxChannelGroups.fcl";
62 cout << myname <<
"Using existing top-level FCL." <<
endl;
64 cout << myname <<
"Creating top-level FCL." <<
endl;
65 ofstream
fout(fclfile.c_str());
68 fout <<
" tool_type: VDColdboxChannelRanges" <<
endl;
70 fout <<
" GhostRange: [3200, 3392]" <<
endl;
73 fout <<
" tool_type: VDColdboxChannelGroups" <<
endl;
80 cout << myname << line <<
endl;
81 cout << myname <<
"Fetching tool manager." <<
endl;
83 assert ( ptm !=
nullptr );
88 cout << myname << line <<
endl;
89 cout << myname <<
"Fetching tool." <<
endl;
91 assert( cma !=
nullptr );
93 cout << myname << line <<
endl;
94 cout << myname <<
"Check detector." <<
endl;
108 cout << myname << line <<
endl;
109 cout << myname <<
"Check U FEMBs." <<
endl;
111 for (
string sran : {
"femb01u",
"femb02u",
"femb03u",
"femb04u",
"femb05u",
112 "femb06u",
"femb07u",
"femb08u",
"femb09u",
"femb10u",
"femb11u" } ) {
115 cout << myname <<
" Checking " << nchuf <<
" == " << nchu <<
endl;
116 assert( nchuf == nchu );
118 cout << myname << line <<
endl;
119 cout << myname <<
"Check Y FEMBs." <<
endl;
121 for (
string sran : {
"femb01y",
"femb02y",
"femb03y",
"femb04y",
122 "femb11y",
"femb12y",
"femb13y" } ) {
125 cout << myname <<
" Checking " << nchyf <<
" == " << nchy <<
endl;
126 assert( nchyf == nchy );
128 cout << myname << line <<
endl;
129 cout << myname <<
"Check Z FEMBs." <<
endl;
131 for (
string sran : {
"femb04z",
"femb05z",
"femb06z",
"femb07z",
132 "femb08z",
"femb09z",
"femb10z",
"femb11z" } ) {
135 cout << myname <<
" Checking " << nchzf <<
" == " << nchz <<
endl;
136 assert( nchzf == nchz );
138 cout << myname << line <<
endl;
139 cout << myname <<
"Check each FEMB." <<
endl;
141 vector<vector<string>> fmbPlanes(14);
142 for (
Index ifmb=1; ifmb<=11; ++ifmb ) fmbPlanes[ifmb].
push_back(
"u");
143 for (
Index ifmb=1; ifmb<=4; ++ifmb ) fmbPlanes[ifmb].
push_back(
"y");
144 for (
Index ifmb=11; ifmb<=13; ++ifmb ) fmbPlanes[ifmb].
push_back(
"y");
145 for (
Index ifmb=4; ifmb<=11; ++ifmb ) fmbPlanes[ifmb].
push_back(
"z");
147 for (
Index ifmb=1; ifmb<=13; ++ifmb ) {
150 for (
string spla : fmbPlanes[ifmb] ) {
151 nchf +=
checkran(*cma, sbas + spla, 0,
false);
153 cout <<
"*** " << sbas <<
" count is " << nchf <<
endl;
154 assert( nchf <= 128 );
157 cout << myname <<
"*** FEMB total is " << ntot <<
endl;
158 assert( ntot == 1600 );
160 cout << myname << line <<
endl;
161 cout << myname <<
"Done." <<
endl;
fInnerVessel push_back(Point(-578.400000, 0.000000, 0.000000))
void line(double t, double *p, double &x, double &y, double &z)
Index checkran(const IndexRangeGroupTool &rm, string sgrp, Index nexp=0, bool chkvalid=true)
std::string to_string(ModuleType const mt)
QTextStream & endl(QTextStream &s)