Opened 5 years ago

Closed 5 years ago

#13149 closed Bugs (fixed)

Dependency decorators on parent suites

Reported by: namezero@… Owned by: Raffi Enficiaud
Milestone: Boost 1.67.0 Component: test
Version: Boost 1.64.0 Severity: Problem
Keywords: boost unit test dependency Cc:

Description

Dependency decorators on parent suites are not honored when a nested test selected to run via command line

Given the following code:

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


BOOST_AUTO_TEST_SUITE(suite1, *boost::unit_test::depends_on("suite2"))

	BOOST_AUTO_TEST_SUITE(suite1_nested)

        BOOST_AUTO_TEST_CASE(suite1_test1)
        {
            BOOST_CHECK(true);
        }

	BOOST_AUTO_TEST_SUITE_END()

BOOST_AUTO_TEST_SUITE_END()

BOOST_AUTO_TEST_SUITE(suite2)

    BOOST_AUTO_TEST_CASE(suite2_test2)
    {
        BOOST_CHECK(true);
    }

BOOST_AUTO_TEST_SUITE_END()

And running with the following command line:

./test.o --log_level=all --run_test=suite1/suite1_nested

The output is as follows:


Running 1 test case...

Entering test module "my_tests"

main.cpp(7): Test suite "suite1" is skipped because dependency test suite "suite2" is disabled

Leaving test module "my_tests"; testing time: 24us

* Errors were detected in the test module "my_tests"; see standard output for details


Expected: The parent's suite (suite1) dependency is honored, and the tests are run.

Change History (6)

comment:3 by Raffi Enficiaud, 5 years ago

Milestone: To Be DeterminedBoost 1.66.0

comment:4 by Raffi Enficiaud, 5 years ago

Owner: changed from Gennadiy Rozental to Raffi Enficiaud
Status: newassigned

comment:5 by Raffi Enficiaud, 5 years ago

Milestone: Boost 1.66.0Boost 1.67.0

comment:6 by Raffi Enficiaud, 5 years ago

Resolution: fixed
Status: assignedclosed

On master

Note: See TracTickets for help on using tickets.