Boost C++ Libraries: Ticket #13170: BOOST_AUTO_TEST_CASE_TEMPLATE don't want typedef for list https://svn.boost.org/trac10/ticket/13170 <p> It is possible to test several types using BOOST_AUTO_TEST_CASE_TEMPLATE </p> <pre class="wiki">typedef boost::mpl::list&lt;int,long,unsigned char&gt; test_types; BOOST_AUTO_TEST_CASE_TEMPLATE( my_test, T, test_types ) { BOOST_TEST( sizeof(T) == (unsigned)4 ); } </pre><p> But if I don't want to introduce a typedef not used elsewhere, as every individual test would have separate type list: </p> <pre class="wiki">BOOST_AUTO_TEST_CASE_TEMPLATE( my_test, T, boost::mpl::list&lt; int, long, unsigned char &gt; ) { BOOST_TEST( sizeof(T) == (unsigned)4 ); } </pre><p> The code above doesn't compile though due to comma in macro. It can be worked around, but workarounds seems to be worse than having extra typedef. </p> <p> I propose using variadic macro for types parameter and make the example above compiling. </p> en-us Boost C++ Libraries /htdocs/site/boost.png https://svn.boost.org/trac10/ticket/13170 Trac 1.4.3 Raffi Enficiaud Tue, 29 Aug 2017 21:37:13 GMT <link>https://svn.boost.org/trac10/ticket/13170#comment:1 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13170#comment:1</guid> <description> <p> does the surrounding with <code>( )</code> like: </p> <pre class="wiki">BOOST_AUTO_TEST_CASE_TEMPLATE( my_test, T, (boost::mpl::list&lt; int, long, unsigned char &gt;) ) </pre><p> prevent the list from being interpreted by the macro expansion? </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Raffi Enficiaud</dc:creator> <pubDate>Wed, 06 Sep 2017 10:37:49 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/13170#comment:2 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13170#comment:2</guid> <description> <p> Kind reminder </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Raffi Enficiaud</dc:creator> <pubDate>Sat, 30 Dec 2017 22:31:55 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/13170#comment:3 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13170#comment:3</guid> <description> <p> Got it working with <code>BOOST_IDENTITY_TYPE</code> from <a href="http://www.boost.org/doc/libs/1_66_0/libs/utility/identity_type/doc/html/index.html">http://www.boost.org/doc/libs/1_66_0/libs/utility/identity_type/doc/html/index.html</a>: </p> <pre class="wiki">#include &lt;boost/utility/identity_type.hpp&gt; BOOST_AUTO_TEST_CASE_TEMPLATE( my_test2, T, BOOST_IDENTITY_TYPE((boost::mpl::list&lt; int, long, unsigned char &gt;)) ) { BOOST_TEST( sizeof(T) == (unsigned)4 ); } </pre><p> I will update the doc accordingly. </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Raffi Enficiaud</dc:creator> <pubDate>Sat, 30 Dec 2017 23:22:54 GMT</pubDate> <title/> <link>https://svn.boost.org/trac10/ticket/13170#comment:4 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13170#comment:4</guid> <description> <p> On next </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Raffi Enficiaud</dc:creator> <pubDate>Sat, 30 Dec 2017 23:23:30 GMT</pubDate> <title>owner, status changed https://svn.boost.org/trac10/ticket/13170#comment:5 https://svn.boost.org/trac10/ticket/13170#comment:5 <ul> <li><strong>owner</strong> changed from <span class="trac-author">Gennadiy Rozental</span> to <span class="trac-author">Raffi Enficiaud</span> </li> <li><strong>status</strong> <span class="trac-field-old">new</span> → <span class="trac-field-new">assigned</span> </li> </ul> Ticket Raffi Enficiaud Tue, 02 Jan 2018 10:06:15 GMT <link>https://svn.boost.org/trac10/ticket/13170#comment:6 </link> <guid isPermaLink="false">https://svn.boost.org/trac10/ticket/13170#comment:6</guid> <description> <p> On develop </p> </description> <category>Ticket</category> </item> <item> <dc:creator>Raffi Enficiaud</dc:creator> <pubDate>Tue, 02 Jan 2018 21:20:46 GMT</pubDate> <title>milestone changed https://svn.boost.org/trac10/ticket/13170#comment:7 https://svn.boost.org/trac10/ticket/13170#comment:7 <ul> <li><strong>milestone</strong> <span class="trac-field-old">To Be Determined</span> → <span class="trac-field-new">Boost 1.66.0</span> </li> </ul> Ticket Raffi Enficiaud Thu, 18 Jan 2018 08:25:11 GMT milestone changed https://svn.boost.org/trac10/ticket/13170#comment:8 https://svn.boost.org/trac10/ticket/13170#comment:8 <ul> <li><strong>milestone</strong> <span class="trac-field-old">Boost 1.66.0</span> → <span class="trac-field-new">Boost 1.67.0</span> </li> </ul> Ticket Raffi Enficiaud Mon, 22 Jan 2018 12:55:56 GMT status changed; resolution set https://svn.boost.org/trac10/ticket/13170#comment:9 https://svn.boost.org/trac10/ticket/13170#comment:9 <ul> <li><strong>status</strong> <span class="trac-field-old">assigned</span> → <span class="trac-field-new">closed</span> </li> <li><strong>resolution</strong> → <span class="trac-field-new">fixed</span> </li> </ul> <p> Documentation changes on master </p> Ticket