Main Page
Class Categories
Classes
Namespaces
File List
File Members
exper-sw
cosmosw
AugerSW
Offline
source
main
Framework
CentralConfig
testCentralConfigAlteredMd5.cc
Go to the documentation of this file.
1
9
#include <string>
10
#include <iostream>
11
#include <sstream>
12
#include <fstream>
13
14
#include <utl/AugerException.h>
15
16
#include <fwk/CentralConfig.h>
17
#include <utl/Reader.h>
18
19
#include <cppunit/extensions/HelperMacros.h>
20
21
using namespace
std;
22
using namespace
utl;
23
using namespace
fwk;
24
25
26
class
CentralConfigTest
:
public
CppUnit::TestFixture {
27
28
CPPUNIT_TEST_SUITE(
CentralConfigTest
);
29
//#warning testAlteredFingerprint with expected exception is commented out! reinstate it once the Md5s are correctly generated in cmake
30
// CPPUNIT_TEST_EXCEPTION(testAlteredFingerprint, InvalidConfigurationException);
31
32
CPPUNIT_TEST_SUITE_END();
33
34
public
:
35
36
void
setUp
() { }
37
38
void
tearDown
() { }
39
40
void
testAlteredFingerprint
()
41
{
42
// Alter contents of the configuration file so that the md5
43
// fingerprint will be different from the one generated at
44
// configuration time. Set up CentralConfig so that an
45
// exception is thrown.
46
47
ofstream
out
(
"./CentralConfig/AlteredMd5.xml"
);
48
49
out <<
"<?xml version='1.0' encoding='iso-8859-1'?> <alteredTag/>"
;
50
out.close();
51
52
CentralConfig::GetInstance(BOOTSTRAPFILE,
true
);
53
}
54
55
};
56
57
CPPUNIT_TEST_SUITE_REGISTRATION
(
CentralConfigTest
);
out
vector< t2list > out
output of the algorithm: a list of clusters
Definition:
XbAlgo.cc:32
CPPUNIT_TEST_SUITE_REGISTRATION
CPPUNIT_TEST_SUITE_REGISTRATION(testAiresShowerFile)
CentralConfigTest::testAlteredFingerprint
void testAlteredFingerprint()
Definition:
testCentralConfigAlteredMd5.cc:40
CentralConfigTest::setUp
void setUp()
Definition:
testCentralConfigAlteredMd5.cc:36
CentralConfigTest
Definition:
testCentralConfig.cc:29
CentralConfigTest::tearDown
void tearDown()
Definition:
testCentralConfigAlteredMd5.cc:38
, generated on Tue Sep 26 2023.