Skip to content
Snippets Groups Projects
Commit 158b5cee authored by Russell Taylor's avatar Russell Taylor
Browse files

Eliminate constructor from ConfigServiceTest. Re #2220.

parent 9489cbf6
No related merge requests found
......@@ -21,11 +21,6 @@ class ConfigServiceTest : public CxxTest::TestSuite
{
public:
ConfigServiceTest() : m_changeObserver(*this, &ConfigServiceTest::handleConfigChange)
{
ConfigService::Instance().updateConfig("MantidTest.properties");
}
void testLogging()
{
//attempt some logging
......@@ -264,11 +259,12 @@ public:
// Test that the ValueChanged notification is sent
void testNotifications()
{
Poco::NObserver<ConfigServiceTest, ConfigServiceImpl::ValueChanged> changeObserver(*this, &ConfigServiceTest::handleConfigChange);
m_valueChangedSent = false;
ConfigServiceImpl& settings = ConfigService::Instance();
TS_ASSERT_THROWS_NOTHING(settings.addObserver(m_changeObserver));
TS_ASSERT_THROWS_NOTHING(settings.addObserver(changeObserver));
settings.setString("default.facility", "SNS");
......@@ -284,7 +280,6 @@ public:
protected:
bool m_valueChangedSent;
Poco::NObserver<ConfigServiceTest, Mantid::Kernel::ConfigServiceImpl::ValueChanged> m_changeObserver;
std::string m_key;
std::string m_preValue;
std::string m_curValue;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment