KratosMultiphysics
KRATOS Multiphysics (Kratos) is a framework for building parallel, multi-disciplinary simulation software, aiming at modularity, extensibility, and high performance. Kratos is written in C++, and counts with an extensive Python interface.
|
Tester class manages all tests and provide interface to run them. More...
#include <tester.h>
Public Types | |
Enums | |
enum class | Verbosity { QUITE , PROGRESS , TESTS_LIST , FAILED_TESTS_OUTPUTS , TESTS_OUTPUTS } |
Type Definitions | |
using | TestCasesContainerType = std::map< std::string, TestCase * > |
using | TestSuitesContainerType = std::map< std::string, TestSuite * > |
Public Member Functions | |
Operators | |
Tester & | operator= (Tester const &rOther)=delete |
Preventing the assignment of the tests. More... | |
Input and output | |
virtual std::string | Info () const |
Turn back information as a string. More... | |
virtual void | PrintInfo (std::ostream &rOStream) const |
Print information about this object. More... | |
virtual void | PrintData (std::ostream &rOStream) const |
Print object's data. More... | |
Static Public Member Functions | |
Operations | |
static void | ResetAllTestCasesResults () |
static int | RunAllTestCases () |
static int | RunAllDistributedTestCases () |
static int | ProfileAllTestCases () |
static int | ProfileAllDistributedTestCases () |
static int | RunTestSuite (std::string const &TestSuiteName) |
static int | ProfileTestSuite (std::string const &TestSuiteName) |
static int | RunTestCases (std::string const &TestCasesNamePattern) |
The test case pattern can apply * as any number of any character. More... | |
static int | ProfileTestCases (std::string const &TestCasesNamePattern) |
The test case pattern can apply * as any number of any character. More... | |
static std::size_t | NumberOfFailedTestCases () |
static std::size_t | NumberOfSkippedTestCases () |
static void | AddTestCase (TestCase *pHeapAllocatedTestCase) |
static TestCase & | GetTestCase (std::string const &TestCaseName) |
static TestCase * | pGetTestCase (std::string const &TestCaseName) |
static TestSuite * | CreateTestSuite (std::string const &TestSuiteName) |
Creates a new test suite or return the already created one. More... | |
static TestSuite * | CreateNewTestSuite (std::string const &TestSuiteName) |
This method gives an error if test suite already exists. More... | |
static void | AddTestSuite (TestSuite *pHeapAllocatedTestSuite) |
static TestSuite & | GetTestSuite (std::string const &TestSuiteName) |
static TestSuite * | pGetTestSuite (std::string const &TestSuiteName) |
static void | AddTestToTestSuite (std::string const &TestName, std::string const &TestSuiteName) |
This method creates the suite if is no exist. More... | |
Access | |
static Tester & | GetInstance () |
static void | SetVerbosity (Verbosity TheVerbosity) |
Inquiry | |
static bool | HasTestCase (std::string const &TestCaseName) |
static bool | HasTestSuite (std::string const &TestSuiteName) |
Life Cycle | |
Tester (Tester const &rOther)=delete | |
The Tester cannot be copied to avoid duplications. More... | |
virtual | ~Tester () |
Destructor. More... | |
Tester class manages all tests and provide interface to run them.
Tester is a singletone class which registers the test cases and test suits and gives interface to register test cases and run all or some of them.
using Kratos::Testing::Tester::TestCasesContainerType = std::map<std::string, TestCase*> |
using Kratos::Testing::Tester::TestSuitesContainerType = std::map<std::string, TestSuite*> |
|
strong |
|
delete |
The Tester cannot be copied to avoid duplications.
|
virtual |
Destructor.
|
static |
This method assumes that the given test case is allocated via new. So it will delete it at the end of the program
|
static |
This method assumes that the given test suite is allocated via new. So it will delete it at the end of the program
|
static |
This method creates the suite if is no exist.
|
static |
This method gives an error if test suite already exists.
|
static |
Creates a new test suite or return the already created one.
|
static |
|
static |
|
static |
|
static |
|
static |
|
virtual |
Turn back information as a string.
|
static |
|
static |
Preventing the assignment of the tests.
|
static |
|
static |
|
virtual |
Print object's data.
|
virtual |
Print information about this object.
|
static |
|
static |
|
static |
The test case pattern can apply * as any number of any character.
|
static |
|
static |
|
static |
|
static |
|
static |
The test case pattern can apply * as any number of any character.
|
static |
|
static |