edbee - Qt Editor Library
Public Member Functions | List of all members
edbee::test::TestCase Class Reference

I really really hate the QTestLib output on my Mac. It's a very ugly xwindows console result. More...

#include <test.h>

+ Inheritance diagram for edbee::test::TestCase:
+ Collaboration diagram for edbee::test::TestCase:

Public Member Functions

 TestCase ()
 Constructs the testcase. More...
 
virtual TestEngineengine ()
 This method returns the current engine. More...
 
virtual void setEngine (TestEngine *engine)
 
virtual OutputHandlerout ()
 this method returns the outputhandler More...
 
virtual void testTrueImpl (bool condition, const char *statement, const QString &description, const char *file, int line)
 The test true implementation. More...
 
virtual void testEqualImpl (bool result, const QString &actual, const QString &expected, const char *actualStatement, const char *expectedStatement, const QString &description, const char *file, int line)
 The test equal implementation. More...
 
virtual void testSkipImpl (const QString &description, const char *file, int line)
 Implements the skip test operation. More...
 
virtual TestCasecurrentTest ()
 this method returns the current testcase More...
 
virtual QString currentMethodName ()
 
virtual void giveTestResultToEngine (TestResult *result)
 Gives the testresult to the engine. More...
 

Detailed Description

I really really hate the QTestLib output on my Mac. It's a very ugly xwindows console result.

This extemely simple testing support class makes it possible for met to output the test results to a WebKit window. Where I can added clickable divs etc. to show test result details

The basic conventions for these tests are the sames as those of QTest. The main difference is the usage of exta output/compare info output messsages A simple unit test. Every private slot is called for a test

Constructor & Destructor Documentation

◆ TestCase()

edbee::test::TestCase::TestCase ( )
explicit

Constructs the testcase.

Member Function Documentation

◆ currentMethodName()

QString edbee::test::TestCase::currentMethodName ( )
virtual

◆ currentTest()

TestCase * edbee::test::TestCase::currentTest ( )
virtual

this method returns the current testcase

◆ engine()

virtual TestEngine* edbee::test::TestCase::engine ( )
inlinevirtual

This method returns the current engine.

◆ giveTestResultToEngine()

void edbee::test::TestCase::giveTestResultToEngine ( TestResult result)
virtual

Gives the testresult to the engine.

◆ out()

OutputHandler * edbee::test::TestCase::out ( )
virtual

this method returns the outputhandler

Returns
the output handler

◆ setEngine()

virtual void edbee::test::TestCase::setEngine ( TestEngine engine)
inlinevirtual

◆ testEqualImpl()

void edbee::test::TestCase::testEqualImpl ( bool  result,
const QString &  actual,
const QString &  expected,
const char *  actualStatement,
const char *  expectedStatement,
const QString &  description,
const char *  file,
int  line 
)
virtual

The test equal implementation.

Parameters
resultthe result of the compare
actualthe actual result
expectedthe expected result
actualStatementthe statement of the operation
exptectedStatementthe expected statement
descriptionthe description of this test item
filethe source file
linethe line number

◆ testSkipImpl()

void edbee::test::TestCase::testSkipImpl ( const QString &  description,
const char *  file,
int  line 
)
virtual

Implements the skip test operation.

Parameters
descriptionthe description of the test
filethe source file
linethe line number

◆ testTrueImpl()

void edbee::test::TestCase::testTrueImpl ( bool  condition,
const char *  statement,
const QString &  description,
const char *  file,
int  line 
)
virtual

The test true implementation.

Parameters
conditionthe condition to test
statementthe statement of the operation
descriptionthe description of this test item
filethe source file
linethe line number

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