Open bartekbl opened 2 years ago
I found a hint on stack overflow that operator<< needs to be defined in the same namespace as the type being printed which in this case means std (because vector comes from std). I think we can close this issue, but this caveat should be mentioned in the docs.
I tried to used boost::test with data driven tests, but one of my input samples is
vector<string>
. Boost::test complains about missing operator<< even when I define it.Self contained example:
fails to build with the error:
/usr/include/boost/type_traits/detail/has_binary_operator.hpp:54:150: error: no match for ‘operator<<’ (operand types are ‘std::basic_ostream<char>’ and ‘std::vector<std::__cxx11::basic_string<char> >’)
see attachment for full error log error.txt
If you comment-out the BOOST_DATA_TEST_CASE it builds and run correctly.