Commit e70e3c8a authored by Florent Lamiraux's avatar Florent Lamiraux Committed by Florent Lamiraux florent@laas.fr

Add a test that sets a signal to empty string.

parent 70864112
......@@ -297,3 +297,19 @@ BOOST_AUTO_TEST_CASE(plug_signal_string) {
std::cout << "res=" << res << std::endl;
BOOST_CHECK(res == str);
}
BOOST_AUTO_TEST_CASE(set_signal_string) {
Signal<std::string, int> s("signal");
std::string str("");
std::ostringstream os;
os << str;
std::istringstream value(os.str());
try {
s.set(value);
}
catch(const std::exception& exc)
{
std::cout << exc.what() << std::endl;
BOOST_CHECK(!"Tentative to set signal to empty string");
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment