boost::unit_test::test_suite — Class representing test suites.
Synopsis
// In header: <boost/test/tree/test_unit.hpp>
classtest_suite:publicboost::unit_test::test_unit{public:// typestypedefstd::vector<test_unit_id>id_list;typedefstd::vector<test_unit_fixture_ptr>fixture_list_t;typedefstd::vector<decorator::base_ptr>decor_list_t;typedefboost::function<test_tools::assertion_result(test_unit_id)>precondition_t;enum@2 { type = = TUT_SUITE };enum@0 { type = = TUT_ANY };enumrun_status { RS_DISABLED, RS_ENABLED, RS_INHERIT, RS_INVALID };// construct/copy/destructexplicittest_suite(const_string,const_string,std::size_t);explicittest_suite(const_string);~test_suite();// public member functionsvoidadd(test_unit*,counter_t=0,unsigned=0);voidadd(test_unit_generatorconst&,unsigned=0);voidadd(test_unit_generatorconst&,decorator::collector&);voidremove(test_unit_id);test_unit_idget(const_string)const;std::size_tsize()const;typedefBOOST_READONLY_PROPERTY(test_unit_id,(framework::state));typedefBOOST_READONLY_PROPERTY(test_unit_id,(test_suite));typedefBOOST_READONLY_PROPERTY(id_list,(test_unit));typedefBOOST_READONLY_PROPERTY(std::vector<std::string>,(test_unit));typedefBOOST_READONLY_PROPERTY(std::vector<precondition_t>,(test_unit));voiddepends_on(test_unit*);voidadd_precondition(precondition_tconst&);test_tools::assertion_resultcheck_preconditions()const;voidadd_label(const_string);boolhas_label(const_string)const;voidincrease_exp_fail(counter_t);boolis_enabled()const;std::stringfull_name()const;// public data memberstest_unit_typeconstp_type;// type for this test unit const_stringconstp_type_name;// "case"/"suite"/"module" const_stringconstp_file_name;std::size_tconstp_line_num;id_tp_id;// unique id for this test unit parent_id_tp_parent_id;// parent test suite id label_list_tp_labels;// list of labels associated with this test unit id_list_tp_dependencies;// list of test units this one depends on precond_list_tp_preconditions;// user supplied preconditions for this test unit; readwrite_property<std::string>p_name;// name for this test unit readwrite_property<std::string>p_description;// description for this test unit readwrite_property<unsigned>p_timeout;// timeout for the test unit execution in seconds readwrite_property<counter_t>p_expected_failures;// number of expected failures in this test unit readwrite_property<run_status>p_default_status;// run status obtained by this unit during setup phase readwrite_property<run_status>p_run_status;// run status assigned to this unit before execution phase after applying all filters readwrite_property<counter_t>p_sibling_rank;// rank of this test unit amoung siblings of the same parent readwrite_property<decor_list_t>p_decorators;// automatically assigned decorators; execution is delayed till framework::finalize_setup_phase function readwrite_property<fixture_list_t>p_fixtures;// fixtures associated with this test unit };
Материалы статей собраны из открытых источников, владелец сайта не претендует на авторство. Там где авторство установить не удалось, материал подаётся без имени автора. В случае если Вы считаете, что Ваши права нарушены, пожалуйста, свяжитесь с владельцем сайта.