Small helper base class for pool tests.
More...
#include <PoolTestBase.h>
Inherited by TestDriver, TestDriver, TestDriver, TestDriver, TestDriver, TestDriver, TestDriver, TestDriver, pool::TestDriver, pool::TestDriver, and pool::TestDriver.
|
| static void | loadLibraries (const std::vector< std::string > &libraries) |
| | load local dictionary libraries for the test
|
Small helper base class for pool tests.
Definition at line 17 of file PoolTestBase.h.
◆ PoolTestBase() [1/2]
| PoolTestBase::PoolTestBase |
( |
| ) |
|
|
default |
◆ PoolTestBase() [2/2]
◆ ~PoolTestBase()
| virtual PoolTestBase::~PoolTestBase |
( |
| ) |
|
|
virtualdefault |
◆ createSession()
| ToolHandle< ISessionTool > PoolTestBase::createSession |
( |
Gaudi::IFileCatalog & | fileCatalog, |
|
|
const std::string & | sessionName ) |
|
inline |
create a session tool for the test with @sessionName, attach the catalog to it
Definition at line 49 of file PoolTestBase.h.
50{
51 std::cout << "Creating the persistency service" << std::endl;
52 auto dbsession = ToolHandle<ISessionTool>("SessionTool/" + sessionName, Gaudi::svcLocator()->service("ToolSvc"));
53 if( !dbsession.retrieve().isSuccess() ) {
54 throw std::runtime_error( "Could not create DB Session" );
55 }
56 dbsession->setupFC( catalog );
57 return dbsession;
58}
◆ loadLibraries()
| void PoolTestBase::loadLibraries |
( |
const std::vector< std::string > & | libraries | ) |
|
|
inlinestatic |
load local dictionary libraries for the test
Definition at line 32 of file PoolTestBase.h.
33{
34 for( std::vector<std::string>::const_iterator iLibrary = libraries.begin();
35 iLibrary != libraries.end(); ++iLibrary ) {
36 const std::string& library = *iLibrary;
37 std::cout << "Loading library " << library << std::endl;
38
39 System::ImageHandle libhandle;
40 if( System::loadDynamicLib(library, &libhandle) != 1 ) {
41 std::cout << "Error! library loading failed" << std::endl;
42 }
43 }
44}
◆ operator=()
The documentation for this class was generated from the following file: