Generated on for Gecode by doxygen 1.17.0

Commandline options. More...

#include <test/test.hh>

Public Member Functions

 Options (void)
 Initialize options with defaults.
void parse (int argc, char *argv[])
 Parse commandline arguments.
bool is_test_name_matching (const std::string &test_name) const
 Test whether a test name should be executed.
bool is_test_tags_matching (TestTags tags) const
 True iff test tags should be executed according to the requested tags. With no tag request, always true.

Public Attributes

unsigned int threads
 Number of threads to use.
unsigned int seed
 The random seed to be used.
bool replay
 Replay one named test from its reported random state.
unsigned int iter
 Number of iterations for each test.
unsigned int fixprob
 The probability for computing a fixpoint.
bool stop
 Whether to stop on an error.
bool log
 Whether to log the tests.
std::vector< std::pair< MatchType, const char * > > testpat
 Patterns to test against.
TestTags testtags
 Tags to test against.
const char * start_from
 Name of first test to start with.
bool list
 Whether to list all tests.
bool list_tags
 Whether to list known tags.
bool list_with_tags
 Whether to include tags when listing tests.

Static Public Attributes

static const int defiter = 5
 Default number of iterations.
static const unsigned int deffixprob = 10
 Default fixpoint probability.

Detailed Description

Commandline options.

Definition at line 133 of file test.hh.

Constructor & Destructor Documentation

◆ Options()

Test::Options::Options ( void )
inline

Initialize options with defaults.

Definition at line 80 of file test.hpp.

Member Function Documentation

◆ parse()

void Test::Options::parse ( int argc,
char * argv[] )

Parse commandline arguments.

Definition at line 177 of file test.cpp.

◆ is_test_name_matching()

bool Test::Options::is_test_name_matching ( const std::string & test_name) const

Test whether a test name should be executed.

Replay requires one exact test name. Otherwise, match the configured patterns; with no patterns, every test name matches.

Definition at line 314 of file test.cpp.

◆ is_test_tags_matching()

bool Test::Options::is_test_tags_matching ( TestTags tags) const

True iff test tags should be executed according to the requested tags. With no tag request, always true.

Definition at line 356 of file test.cpp.

Member Data Documentation

◆ threads

unsigned int Test::Options::threads

Number of threads to use.

Definition at line 136 of file test.hh.

◆ seed

unsigned int Test::Options::seed

The random seed to be used.

Definition at line 138 of file test.hh.

◆ replay

bool Test::Options::replay

Replay one named test from its reported random state.

Definition at line 140 of file test.hh.

◆ iter

unsigned int Test::Options::iter

Number of iterations for each test.

Definition at line 142 of file test.hh.

◆ defiter

const int Test::Options::defiter = 5
static

Default number of iterations.

Definition at line 144 of file test.hh.

◆ fixprob

unsigned int Test::Options::fixprob

The probability for computing a fixpoint.

Definition at line 146 of file test.hh.

◆ deffixprob

const unsigned int Test::Options::deffixprob = 10
static

Default fixpoint probability.

Definition at line 148 of file test.hh.

◆ stop

bool Test::Options::stop

Whether to stop on an error.

Definition at line 150 of file test.hh.

◆ log

bool Test::Options::log

Whether to log the tests.

Definition at line 152 of file test.hh.

◆ testpat

std::vector<std::pair<MatchType, const char*> > Test::Options::testpat

Patterns to test against.

Definition at line 154 of file test.hh.

◆ testtags

TestTags Test::Options::testtags

Tags to test against.

Definition at line 156 of file test.hh.

◆ start_from

const char* Test::Options::start_from

Name of first test to start with.

Definition at line 158 of file test.hh.

◆ list

bool Test::Options::list

Whether to list all tests.

Definition at line 160 of file test.hh.

◆ list_tags

bool Test::Options::list_tags

Whether to list known tags.

Definition at line 162 of file test.hh.

◆ list_with_tags

bool Test::Options::list_with_tags

Whether to include tags when listing tests.

Definition at line 164 of file test.hh.


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