NdmcClientServiceTest.cpp
Go to the documentation of this file.
2 using namespace NDMC_NAMESPACE;
3 
4 /**
5  * Register the NdmcClientServiceTest suite in the registry of suites in a "folder"
6  * of name "NovaDAQMonitorClient". Store the folder in the default registry path.
7  * $Id: NdmcClientServiceTest.cpp,v 1.4 2010/07/27 15:11:21 kasahara Exp $
8  */
10 CPPUNIT_REGISTRY_ADD_TO_DEFAULT("NovaDAQMonitorClient");
11 
12 /**
13  * A public method to setUp the environment for the test. This will be invoked before
14  * every test in the fixture to get a fresh start.
15  */
17  _configFile = getConfigFullFilePathName("unittest/gmond.conf");
18 }
19 /**
20  * A public method to tearDown the environment for the test. This will be invoked after
21  * every test in the fixture to clean up allocated memory.
22  */
24  std::cout.flush();
25 }
26 
27 /**
28  * A test method to test that NdmcClient::instance()
29  * works correctly.
30  */
32 
34  NdmcClientService& daqmonitorclientservice = NdmcClientService::instance();
35  CPPUNIT_ASSERT(daqmonitorclientservice.isEnabled() == true);
36 
37 }
38 
CPPUNIT_TEST_SUITE_NAMED_REGISTRATION(NdmcClientServiceTest,"NovaDAQMonitorClient")
CPPUNIT_REGISTRY_ADD_TO_DEFAULT("NovaDAQMonitorClient")
static void setCONFIGFILE(std::string configfile)
NDMC_NAMESPACE_BEGIN std::string getConfigFullFilePathName(std::string configFile)
bool isEnabled() const
OStream cout
Definition: OStream.cxx:6
static NdmcClientService & instance()