Opened 7 years ago
Closed 7 years ago
#11890 closed Bugs (duplicate)
BOOST_DATA_TEST_CASE fails to compile for 4D and higher dimensional grids
Reported by: | Owned by: | Gennadiy Rozental | |
---|---|---|---|
Milestone: | To Be Determined | Component: | test |
Version: | Boost 1.60.0 | Severity: | Problem |
Keywords: | Cc: |
Description
Compiling the following code with GCC 5.3.0 (C++11/14) I get an error on the second but not on the first test case.
#include <boost/test/included/unit_test.hpp> #include <boost/test/data/test_case.hpp> using boost::unit_test::data::xrange; BOOST_DATA_TEST_CASE(Test_3D_grid, xrange(2) * xrange(2) * xrange(2), a, b, c) {} BOOST_DATA_TEST_CASE(Test_4D_grid, xrange(2) * xrange(2) * xrange(2) * xrange(2), a, b, c, d) {}
The error reads
/usr/include/boost/test/data/test_case.hpp:107:5: error: no matching function for call to 'bind(<unresolved overloaded function type>, const std::tuple<int, int, int>&, const int&)' BOOST_PP_REPEAT_FROM_TO(1, 4, TC_MAKE, _)
Are four and more parameters not supported for data test cases?
The documentation says
BOOST_DATA_TEST_CASE(test_case_name, dataset, var1, ..., varN) { /* datasets of arity N */ }
without giving any limits on N.
Note:
See TracTickets
for help on using tickets.
Duplicate of #11889