regression_test_metric_generator< MetricSet > Class Template Reference

#include <metric_generator.h>

Inheritance diagram for regression_test_metric_generator< MetricSet >:
abstract_regression_test_generator< MetricSet > abstract_generator< MetricSet >

Public Types

typedef abstract_regression_test_generator< MetricSet >::parent_type parent_type
 
- Public Types inherited from abstract_regression_test_generator< MetricSet >
typedef abstract_generator< MetricSet >::parent_type base_t
 
- Public Types inherited from abstract_generator< MetricSet >
typedef generator_ptr< MetricSet > parent_type
 

Public Member Functions

 regression_test_metric_generator ()
 
 regression_test_metric_generator (const std::string &run_folder)
 
- Public Member Functions inherited from abstract_regression_test_generator< MetricSet >
 abstract_regression_test_generator (const std::string &test_dir, const int test_modifier=0)
 
 abstract_regression_test_generator (const std::string &run_folder, const std::string &test_dir, const int test_modifier=0)
 
base_t operator() (const std::string &name) const
 
::testing::AssertionResult generate (MetricSet &expected, MetricSet &actual, bool *skip_test) const
 
- Public Member Functions inherited from abstract_generator< MetricSet >
 abstract_generator (const int test_modifier=0)
 
virtual ~abstract_generator ()
 
virtual bool advance ()
 
int test_modifier () const
 
std::string info () const
 

Protected Member Functions

bool read_expected (const std::string &baseline_file, metric_set_t &expected) const
 
bool generate_actual (const std::string &run_folder, metric_set_t &actual) const
 
bool write_actual (const std::string &baseline_file, const metric_set_t &actual) const
 
base_type clone (const std::string &run_folder) const
 
base_type clone () const
 
void write (std::ostream &out) const
 
std::string baseline () const
 

Additional Inherited Members

- Protected Attributes inherited from abstract_regression_test_generator< MetricSet >
std::string m_run_folder
 
std::string m_test_dir
 

Detailed Description

template<class MetricSet>
class illumina::interop::unittest::regression_test_metric_generator< MetricSet >

Generate the actual metric set writing out the expected and reading it back in again

The expected metric set is provided by the generator.

Member Typedef Documentation

Constructor & Destructor Documentation

Constructor

regression_test_metric_generator ( const std::string &  run_folder)
inline

Constructor

Parameters
run_folderrun folder

Member Function Documentation

std::string baseline ( ) const
inlineprotectedvirtual

Get the full path of the baseline output file

Returns
full path

Reimplemented from abstract_regression_test_generator< MetricSet >.

base_type clone ( const std::string &  run_folder) const
inlineprotectedvirtual

Create a copy of the current object with the given run folder

Parameters
run_folderrun folder
Returns
pointer to new copy

Implements abstract_regression_test_generator< MetricSet >.

base_type clone ( ) const
inlineprotectedvirtual

Create a copy of the current object

Returns
pointer to new copy

Implements abstract_regression_test_generator< MetricSet >.

bool generate_actual ( const std::string &  run_folder,
metric_set_t &  actual 
) const
inlineprotectedvirtual

Read the actual data from the run folder

Parameters
run_folderrun folder
actualactual model data

Implements abstract_regression_test_generator< MetricSet >.

bool read_expected ( const std::string &  baseline_file,
metric_set_t &  expected 
) const
inlineprotectedvirtual

Read the expected data from the baseline file into the model

Parameters
baseline_filebaseline file
expectedexpected model data
Returns
true if the file was found, and the read completed without failure

Implements abstract_regression_test_generator< MetricSet >.

void write ( std::ostream &  out) const
inlineprotectedvirtual

Write generator info to output stream

Parameters
outoutput stream

Implements abstract_generator< MetricSet >.

bool write_actual ( const std::string &  baseline_file,
const metric_set_t &  actual 
) const
inlineprotectedvirtual

Write the actual data to the run folder

Parameters
baseline_filebaseline file
actualactual model data

Implements abstract_regression_test_generator< MetricSet >.


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