gotthard2 testing

This commit is contained in:
maliakal_d 2020-01-29 14:34:23 +01:00
parent 5761642da0
commit ac3230c656
3 changed files with 95 additions and 384 deletions

View File

@ -24,7 +24,7 @@ TEST_CASE("Setting and reading back GOTTHARD2 dacs", "[.cmd][.dacs]") {
Detector det;
CmdProxy proxy(&det);
auto det_type = det.getDetectorType().squash();
if (det_type == defs::MYTHEN3) {
if (det_type == defs::GOTTHARD2) {
SECTION("vref_h_adc") { test_dac(defs::VREF_H_ADC, "vref_h_adc", 2099); }
SECTION("vb_comp_fe") { test_dac(defs::VB_COMP_FE, "vb_comp_fe", 0); }
SECTION("vb_comp_adc") { test_dac(defs::VB_COMP_ADC, "vb_comp_adc", 0); }
@ -108,15 +108,15 @@ TEST_CASE("vchip", "[.cmd][.onchipdacs]") {
REQUIRE_THROWS(proxy.Call(on_chip_dac_names[i], {"-1", "0x400"}, -1, GET)); // max val is 0x3ff
auto previous = det.getOnChipDAC(on_chip_dac_indices[i], -1);
auto dacstr = std::to_string(values[i]);
auto dacstr = sls::ToStringHex(values[i]);
int chip_index = -1;
auto chip_index_str = std::to_string(chip_index);
std::ostringstream oss_set, oss_get;
proxy.Call(on_chip_dac_names[i], {chip_index_str, dacstr}, -1, PUT, oss_set);
REQUIRE(oss_set.str() == on_chip_dac_names[i] + " " + dacstr + "\n");
REQUIRE(oss_set.str() == on_chip_dac_names[i] + " " + chip_index_str + " " + dacstr + "\n");
proxy.Call(on_chip_dac_names[i], {chip_index_str}, -1, GET, oss_get);
REQUIRE(oss_get.str() == on_chip_dac_names[i] + " " + dacstr + "\n");
REQUIRE(oss_get.str() == on_chip_dac_names[i] + " " + chip_index_str + " " + dacstr + "\n");
// Reset all dacs to previous value
for (int i = 0; i != det.size(); ++i) {
det.setOnChipDAC(on_chip_dac_indices[i], chip_index, previous[i], {i});
@ -133,3 +133,94 @@ TEST_CASE("vchip", "[.cmd][.onchipdacs]") {
}
TEST_CASE("burstmode", "[.cmd]") {
Detector det;
CmdProxy proxy(&det);
auto det_type = det.getDetectorType().squash();
if (det_type == defs::GOTTHARD2) {
auto burst = det.getBurstMode();
auto burststr = sls::ToString(burst);
{
std::ostringstream oss;
proxy.Call("burstmode", {"internal"}, -1, PUT, oss);
REQUIRE(oss.str() == "burstmode internal\n");
}
{
std::ostringstream oss;
proxy.Call("burstmode", {"off"}, -1, PUT, oss);
REQUIRE(oss.str() == "burstmode off\n");
}
{
std::ostringstream oss;
proxy.Call("burstmode", {}, -1, GET, oss);
REQUIRE(oss.str() == "burstmode off\n");
}
for (int i = 0; i != det.size(); ++i) {
det.setBurstMode(burst[i], {i});
}
} else {
REQUIRE_THROWS(proxy.Call("burstmode", {}, -1, GET));
}
}
TEST_CASE("vetoref", "[.cmd]") {
Detector det;
CmdProxy proxy(&det);
auto det_type = det.getDetectorType().squash();
if (det_type == defs::GOTTHARD2) {
REQUIRE_THROWS(proxy.Call("vetoref", {}, -1, GET));
REQUIRE_THROWS(proxy.Call("vetoref", {"3", "0x3ff"}, -1, PUT)); // invalid chip index
REQUIRE_NOTHROW(proxy.Call("vetoref", {"1", "0x010"}, -1, PUT));
} else {
REQUIRE_THROWS(proxy.Call("vetoref", {"3", "0x0"}, -1, PUT));
}
}
TEST_CASE("vetophoton", "[.cmd]") {
Detector det;
CmdProxy proxy(&det);
auto det_type = det.getDetectorType().squash();
if (det_type == defs::GOTTHARD2) {
REQUIRE_THROWS(proxy.Call("vetophoton", {}, -1, GET));
REQUIRE_NOTHROW(proxy.Call("vetophoton", {"-1"}, -1, GET));
REQUIRE_THROWS(proxy.Call("vetophoton", {"12", "1", "39950"}, -1, PUT));// invalid chip index
REQUIRE_THROWS(proxy.Call("vetophoton", {"-1", "0"}, -1, PUT)); // invalid photon number
REQUIRE_THROWS(proxy.Call("vetophoton", {"-1", "1", "39950"}, -1, PUT)); // invald file
} else {
REQUIRE_THROWS(proxy.Call("vetophoton", {"-1"}, -1, GET));
}
}
TEST_CASE("inj_ch", "[.cmd]") {
Detector det;
CmdProxy proxy(&det);
auto det_type = det.getDetectorType().squash();
if (det_type == defs::GOTTHARD2) {
auto inj = det.getInjectChannel();
REQUIRE_THROWS(proxy.Call("inj_ch", {"-1", "1"}, -1, PUT));// invalid offset
REQUIRE_THROWS(proxy.Call("inj_ch", {"0", "0"}, -1, PUT));// invalid increment
{
std::ostringstream oss;
proxy.Call("inj_ch", {"0", "1"}, -1, PUT, oss);
REQUIRE(oss.str() == "inj_ch [0, 1]\n");
}
{
std::ostringstream oss;
proxy.Call("inj_ch", {}, -1, GET, oss);
REQUIRE(oss.str() == "inj_ch [0, 1]\n");
}
for (int i = 0; i != det.size(); ++i) {
det.setInjectChannel(inj[i][0], inj[i][1], {i});
}
} else {
REQUIRE_THROWS(proxy.Call("inj_ch", {}, -1, GET));
}
}

View File

@ -479,42 +479,7 @@ TEST_CASE("rx_zmqip", "[.cmd]") {
}
}
// TEST_CASE("burstmode", "[.cmd][.gotthard2]") {
// if (test::type == slsDetectorDefs::GOTTHARD2) {
// REQUIRE_NOTHROW(multiSlsDetectorClient("burstmode 0", PUT));
// REQUIRE_NOTHROW(multiSlsDetectorClient("burstmode 1", PUT));
// REQUIRE_NOTHROW(multiSlsDetectorClient("burstmode", GET));
// } else {
// REQUIRE_THROWS(multiSlsDetectorClient("burstmod", GET));
// }
// }
// TEST_CASE("vetoref", "[.cmd][.gotthard2]") {
// if (test::type == slsDetectorDefs::GOTTHARD2) {
// REQUIRE_THROWS(multiSlsDetectorClient("vetoref 3 0x3ff", PUT)); //
// invalid chip index REQUIRE_THROWS(multiSlsDetectorClient("vetoref 0
// 0xFFFF", PUT)); // invalid value
// REQUIRE_NOTHROW(multiSlsDetectorClient("vetoref 1 0x010", PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vetoref", GET));
// } else {
// REQUIRE_THROWS(multiSlsDetectorClient("vetoref 3 0x0", PUT));
// }
// }
// TEST_CASE("vetophoton", "[.cmd][.gotthard2]") {
// if (test::type == slsDetectorDefs::GOTTHARD2) {
// REQUIRE_THROWS(multiSlsDetectorClient("vetophoton 12 1 39950
// examples/gotthard2_veto_photon.txt", PUT)); // invalid chip index
// REQUIRE_THROWS(multiSlsDetectorClient("vetophoton -1 0 39950
// examples/gotthard2_veto_photon.txt", PUT)); // invalid photon number
// REQUIRE_NOTHROW(multiSlsDetectorClient("vetophoton -1 1 39950
// examples/gotthard2_veto_photon.txt", PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vetophoton", GET));
// REQUIRE_NOTHROW(multiSlsDetectorClient("vetophoton -1", GET));
// } else {
// REQUIRE_THROWS(multiSlsDetectorClient("vetophoton -1", GET));
// }
// }
// TEST_CASE("inj_ch", "[.cmd][.gotthard2]") {
// if (test::type == slsDetectorDefs::GOTTHARD2) {

View File

@ -34,120 +34,7 @@ TEST_CASE("type", "[.cmd]"){
}
// TEST_CASE("vchip", "[.cmd]") {
// int prev_val = 0;
// if (test::type == slsDetectorDefs::GOTTHARD2) {
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_comp_fe", GET)); //
// needs a chip index
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_comp_fe -1 0x400",
// GET)); // max val is 0x3ff
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_fe -1", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_comp_fe -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_fe -1 0x137",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_fe -1", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vchip_comp_fe -1 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_fe -1 " +
// sls::ToStringHex(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_opa_1st", GET)); //
// needs a chip index
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_1st -1", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_opa_1st -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_1st -1 0x137",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_1st -1", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vchip_opa_1st -1 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_1st -1 " +
// sls::ToStringHex(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_opa_fd", GET)); // needs
// a chip index
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_fd -1", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_opa_fd -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_fd -1 0x137",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_fd -1", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vchip_opa_fd -1 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_opa_fd -1 " +
// sls::ToStringHex(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_comp_adc", GET)); //
// needs a chip index
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_adc -1", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_comp_adc -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_adc -1 0x137",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_adc -1", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vchip_comp_adc -1
// 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_comp_adc -1 " +
// sls::ToStringHex(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_ref_comp_fe", GET)); //
// needs a chip index
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_ref_comp_fe -1",
// GET, nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_ref_comp_fe -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_ref_comp_fe -1
// 0x137", PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_ref_comp_fe -1",
// GET, nullptr, oss)); REQUIRE(oss.str() == "vchip_ref_comp_fe -1
// 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_ref_comp_fe -1 " +
// sls::ToStringHex(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_cs", GET)); // needs a
// chip index
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_cs -1", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vchip_cs -1 ")); prev_val = stoul(s, 0, 16);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_cs -1 0x137",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_cs -1", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vchip_cs -1 0x137\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vchip_cs -1 " +
// sls::ToStringHex(prev_val), PUT));
// } else {
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_comp_fe", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_opa_1st", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_opa_fd", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_comp_adc", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_ref_comp_fe", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vchip_cs", GET));
// }
// }
// TEST_CASE("dacs", "[.cmd]") {
// REQUIRE_NOTHROW(multiSlsDetectorClient("daclist", GET));
@ -574,238 +461,6 @@ TEST_CASE("type", "[.cmd]"){
// REQUIRE_THROWS(multiSlsDetectorClient("vdd_prot", GET));
// }
// else if (test::type == slsDetectorDefs::GOTTHARD2) {
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_h_adc", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vref_h_adc ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_h_adc 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_h_adc", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vref_h_adc 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_h_adc " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_fe", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vb_comp_fe ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_fe 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_fe", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vb_comp_fe 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_fe " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_adc", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vb_comp_adc ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_adc 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_adc", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vb_comp_adc 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_comp_adc " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_cds", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vcom_cds
// ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_cds 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_cds", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vcom_cds 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_cds " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_rstore", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vref_rstore ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_rstore 1000",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_rstore", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vref_rstore 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_rstore " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_1st", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vb_opa_1st ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_1st 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_1st", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vb_opa_1st 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_1st " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_comp_fe", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vref_comp_fe ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_comp_fe 1000",
// PUT)); std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_comp_fe", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vref_comp_fe 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_comp_fe " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc1", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vcom_adc1
// ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc1 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc1", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vcom_adc1 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc1 " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_prech", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vref_prech ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_prech 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_prech", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vref_prech 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_prech " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_l_adc", GET,
// nullptr, oss)); std::string s = (oss.str()).erase (0,
// strlen("vref_l_adc ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_l_adc 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_l_adc", GET,
// nullptr, oss)); REQUIRE(oss.str() == "vref_l_adc 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_l_adc " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_cds", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vref_cds
// ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_cds 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_cds", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vref_cds 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vref_cds " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_cs", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vb_cs "));
// prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_cs 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_cs", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vb_cs 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_cs " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_fd", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vb_opa_fd
// ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_fd 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_fd", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vb_opa_fd 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vb_opa_fd " +
// std::to_string(prev_val), PUT));
// {
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc2", GET, nullptr,
// oss)); std::string s = (oss.str()).erase (0, strlen("vcom_adc2
// ")); prev_val = std::stoi(s);
// }
// {
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc2 1000", PUT));
// std::ostringstream oss;
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc2", GET, nullptr,
// oss)); REQUIRE(oss.str() == "vcom_adc2 1000\n");
// }
// REQUIRE_NOTHROW(multiSlsDetectorClient("vcom_adc2 " +
// std::to_string(prev_val), PUT));
// REQUIRE_THROWS(multiSlsDetectorClient("vthreshold", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vsvp", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vsvn", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vtr", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vrf", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vrs", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vtgstv", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcmp_ll", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcmp_lr", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcal", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcmp_rl", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcmp_rr", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("rxb_rb", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("rxb_lb", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcp", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcn", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vis", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("iodelay", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vref_ds", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcascn_pb", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcascp_pb", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vout_cm", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vcasc_out", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vin_cm", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vref_comp", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("ib_test_c", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vb_ds", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vb_comp", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vb_pixbuf", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vin_com", GET));
// REQUIRE_THROWS(multiSlsDetectorClient("vdd_prot", GET));
// }
// }
TEST_CASE("user", "[.cmd]") {