9#include"unit_testing.h"
11UnitTesting::UnitTesting()
132 cout <<
"void assert_true(bool, const string&) method failed\n";
133 cout << error_message;
158 cout <<
"void assert_false(bool, const string&) method failed\n";
159 cout << error_message;
184 cout <<
"Test case OK." << endl;
Index get_tests_failed_count() const
Returns the number of tests which have failed the test case.
const bool & get_display() const
Returns the display messages to the screen value of this object.
Index tests_failed_count
Number of tests which have failed the test case.
Index tests_count
Number of performed tests.
virtual void run_test_case()=0
This method runs all the methods contained in the test case.
virtual ~UnitTesting()
Destructor.
void assert_false(const bool &, const string &)
bool display
True if messages from this class are to be displayed, false otherwise.
void set_tests_failed_count(const Index &)
Index tests_passed_count
Number of tests which have passed the test case.
void set_tests_count(const Index &)
void set_tests_passed_count(const Index &)
Index random_tests_number
Number of iterations in random tests loops.
Index get_tests_count() const
Returns the number of tests which have been performed by the test case.
void assert_true(const bool &, const string &)
Index get_random_tests_number() const
Returns the number of iterations for loops of random tests.
void set_display(const bool &)
void set_random_tests_number(const Index &)
Index get_tests_passed_count() const
Returns the number of tests which have passed the test case.