OpenWalnut
1.4.0
|
Tests the WModuleConnector class. More...
#include <WModuleConnector_test.h>
Public Member Functions | |
void | setUp () |
Setup logger and other stuff for each test. More... | |
void | createModules (void) |
Initialized the test modules. More... | |
void | initModules (void) |
Initializes modules. More... | |
void | initConnections (void) |
Initialize some connections. More... | |
void | testModuleCreation (void) |
Test whether modules can be created without exception and proper initialization of connection lists. More... | |
void | testModuleInitialization (void) |
Test whether modules can be initialized without problems. More... | |
void | testModuleTwiceInitialization (void) |
Test whether module initialization is robust against double init. More... | |
void | testModuleConnectorCompatibility (void) |
Test whether automatic compatibility check works. More... | |
void | testModuleConnectorTypeCompatibility (void) |
Test whether automatic type compatibility check works. More... | |
void | testModuleConnection (void) |
Test whether connection works properly. More... | |
void | testModuleTwiceConnection (void) |
Test whether connecting twice is not possible. More... | |
void | testModuleDisconnect (void) |
Test whether the connection can properly be disconnected. More... | |
void | testModuleDisconnectAll (void) |
Test whether all connections can be removed in one step. More... | |
void | testModuleCleanup (void) |
Test whether module clean up is working properly. More... | |
void | testModulePropagateDataChange (void) |
Tests the propagation of data. More... | |
void | testModuleInvalidData (void) |
Tests several cases of unset data. More... | |
Public Attributes | |
boost::shared_ptr< WModuleImpl > | m1 |
Simple module to test with. More... | |
boost::shared_ptr< WModuleImpl > | m2 |
Simple module to test with. More... | |
boost::shared_ptr< WModuleImpl > | m3 |
Simple module to test with. More... | |
Tests the WModuleConnector class.
We use WModuleConnector's direct derived classes WModuleInputConnector and WModuleOutputConnector to test their common functionality implemented in WModuleConnector (which has pure virtual members -> so can't be instantiated directly).
Definition at line 361 of file WModuleConnector_test.h.
|
inline |
Initialized the test modules.
Definition at line 390 of file WModuleConnector_test.h.
Referenced by testModuleCleanup(), testModuleConnection(), testModuleConnectorCompatibility(), testModuleConnectorTypeCompatibility(), testModuleCreation(), testModuleDisconnect(), testModuleDisconnectAll(), testModuleInitialization(), testModuleInvalidData(), testModulePropagateDataChange(), testModuleTwiceConnection(), and testModuleTwiceInitialization().
|
inline |
Initialize some connections.
Definition at line 411 of file WModuleConnector_test.h.
Referenced by testModuleCleanup(), testModuleConnection(), testModuleDisconnect(), testModuleDisconnectAll(), testModuleInvalidData(), testModulePropagateDataChange(), and testModuleTwiceConnection().
|
inline |
Initializes modules.
This is normally done by the module container.
Definition at line 401 of file WModuleConnector_test.h.
Referenced by testModuleCleanup(), testModuleConnection(), testModuleConnectorCompatibility(), testModuleConnectorTypeCompatibility(), testModuleDisconnect(), testModuleDisconnectAll(), testModuleInitialization(), testModuleInvalidData(), testModulePropagateDataChange(), testModuleTwiceConnection(), and testModuleTwiceInitialization().
|
inline |
Setup logger and other stuff for each test.
Definition at line 367 of file WModuleConnector_test.h.
References WLogger::startup().
|
inline |
Test whether module clean up is working properly.
Definition at line 600 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether connection works properly.
Definition at line 520 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether automatic compatibility check works.
Definition at line 473 of file WModuleConnector_test.h.
References createModules(), WException::disableBacktrace(), and initModules().
|
inline |
Test whether automatic type compatibility check works.
Definition at line 494 of file WModuleConnector_test.h.
References createModules(), WException::disableBacktrace(), and initModules().
|
inline |
Test whether modules can be created without exception and proper initialization of connection lists.
Definition at line 421 of file WModuleConnector_test.h.
References createModules().
|
inline |
Test whether the connection can properly be disconnected.
Definition at line 555 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether all connections can be removed in one step.
Definition at line 577 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether modules can be initialized without problems.
Definition at line 435 of file WModuleConnector_test.h.
References createModules(), and initModules().
|
inline |
Tests several cases of unset data.
Definition at line 635 of file WModuleConnector_test.h.
References createModules(), WException::disableBacktrace(), initConnections(), and initModules().
|
inline |
Tests the propagation of data.
Definition at line 614 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether connecting twice is not possible.
Definition at line 537 of file WModuleConnector_test.h.
References createModules(), initConnections(), and initModules().
|
inline |
Test whether module initialization is robust against double init.
Definition at line 458 of file WModuleConnector_test.h.
References createModules(), WException::disableBacktrace(), and initModules().
boost::shared_ptr< WModuleImpl > WModuleConnectorTest::m1 |
Simple module to test with.
Definition at line 375 of file WModuleConnector_test.h.
boost::shared_ptr< WModuleImpl > WModuleConnectorTest::m2 |
Simple module to test with.
Definition at line 380 of file WModuleConnector_test.h.
boost::shared_ptr< WModuleImpl > WModuleConnectorTest::m3 |
Simple module to test with.
Definition at line 385 of file WModuleConnector_test.h.