Tests: Runtime type_mismatch after upgrade to 1.69

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Tests: Runtime type_mismatch after upgrade to 1.69

Boost - Users mailing list
Crosspost from boost, haven't received any reply there, see also: https://github.com/boostorg/test/issues/199

Hello,

after my distribution rolled out the upgrade to Boost 1.69 I am unable to compile my application anymore.

I try to get the log_level set. Minimal compiling example:


#define BOOST_TEST_DYN_LINK
#include <boost/test/unit_test.hpp>
#include <boost/test/unit_test_parameters.hpp>

bool init_unit_test()
{
  using namespace boost::unit_test;
 
  auto logLevel = runtime_config::get<log_level>(runtime_config::btrt_log_level);
  return true;
}

int main(int argc, char* argv[])
{
  int retCode = boost::unit_test::unit_test_main( &init_unit_test, argc, argv );
  return retCode;
}


which compiles fine g++ -std=c++11 -lboost_unit_test_framework boosttesting.cpp

but gives an runtime error:

 % ./a.out
Test setup error: boost::runtime::arg_type_mismatch: Access with invalid type for argument corresponding to parameter log_level

Thanks!
Florian
_______________________________________________
Boost-users mailing list
[hidden email]
https://lists.boost.org/mailman/listinfo.cgi/boost-users
Reply | Threaded
Open this post in threaded view
|

Re: Tests: Runtime type_mismatch after upgrade to 1.69

Boost - Users mailing list
On 01.02.19 09:22, Florian Lindner via Boost-users wrote:

> Crosspost from boost, haven't received any reply there, see also: https://github.com/boostorg/test/issues/199
>
> Hello,
>
> after my distribution rolled out the upgrade to Boost 1.69 I am unable to compile my application anymore.
>
> I try to get the log_level set. Minimal compiling example:
>
>
> #define BOOST_TEST_DYN_LINK
> #include <boost/test/unit_test.hpp>
> #include <boost/test/unit_test_parameters.hpp>
>
> bool init_unit_test()
> {
>   using namespace boost::unit_test;
>  
>   auto logLevel = runtime_config::get<log_level>(runtime_config::btrt_log_level);
>   return true;
> }
>
> int main(int argc, char* argv[])
> {
>   int retCode = boost::unit_test::unit_test_main( &init_unit_test, argc, argv );
>   return retCode;
> }
>
>
> which compiles fine g++ -std=c++11 -lboost_unit_test_framework boosttesting.cpp
>
> but gives an runtime error:
>
>  % ./a.out
> Test setup error: boost::runtime::arg_type_mismatch: Access with invalid type for argument corresponding to parameter log_level
>
> Thanks!
> Florian
>

Fixed for 1.70, the issue was related to the visibility changes that
happened in 1.69 on boost.build.

Raffi

_______________________________________________
Boost-users mailing list
[hidden email]
https://lists.boost.org/mailman/listinfo.cgi/boost-users