LArSoft  v09_90_00
Liquid Argon Software toolkit - https://larsoft.org/
testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS > Struct Template Reference

Class holding a configuration for a Boost test fixture. More...

#include "boost_unit_test_base.h"

Inheritance diagram for testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >:

Public Types

using Base_t = CONFIGURATIONCLASS
 

Public Member Functions

 BoostCommandLineConfiguration ()
 Default constructor; this is what is used in Boost unit test. More...
 
 BoostCommandLineConfiguration (std::string name)
 Constructor; accepts the name as parameter. More...
 

Protected Member Functions

void ParseCommandLineFromBoost ()
 Parses arguments as delivered by Boost. More...
 

Detailed Description

template<typename CONFIGURATIONCLASS>
struct testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >

Class holding a configuration for a Boost test fixture.


Template Parameters
CONFIGURATIONCLASSa base configuration class
See also
BasicEnvironmentConfiguration, TesterEnvironment

This class needs to be fully constructed by the default constructor in order to be useful as Boost unit test fixture. It is supposed to be passed as a template parameter to another class that can store an instance of it and extract configuration information from it.

This template just adds to the standard construction of the wrapped class a configuration that reads the parameters from the command line. It also hides all the constructors except two.

Definition at line 51 of file boost_unit_test_base.h.

Member Typedef Documentation

template<typename CONFIGURATIONCLASS >
using testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::Base_t = CONFIGURATIONCLASS

Definition at line 53 of file boost_unit_test_base.h.

Constructor & Destructor Documentation

template<typename CONFIGURATIONCLASS >
testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::BoostCommandLineConfiguration ( )
inline

Default constructor; this is what is used in Boost unit test.

Definition at line 56 of file boost_unit_test_base.h.

References testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::ParseCommandLineFromBoost().

void ParseCommandLineFromBoost()
Parses arguments as delivered by Boost.
template<typename CONFIGURATIONCLASS >
testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::BoostCommandLineConfiguration ( std::string  name)
inline

Constructor; accepts the name as parameter.

Definition at line 59 of file boost_unit_test_base.h.

References testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::ParseCommandLineFromBoost().

59 : Base_t(name) { ParseCommandLineFromBoost(); }
void ParseCommandLineFromBoost()
Parses arguments as delivered by Boost.

Member Function Documentation

template<typename CONFIGURATIONCLASS >
void testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::ParseCommandLineFromBoost ( )
inlineprotected

Parses arguments as delivered by Boost.

Definition at line 63 of file boost_unit_test_base.h.

Referenced by testing::BoostCommandLineConfiguration< CONFIGURATIONCLASS >::BoostCommandLineConfiguration().

64  {
65  Base_t::ParseCommandLine(boost::unit_test::framework::master_test_suite().argc,
66  boost::unit_test::framework::master_test_suite().argv);
67  }

The documentation for this struct was generated from the following file: