]> git.uio.no Git - u/mrichter/AliRoot.git/blob - ITS/TestPreprocessorSSD.C
Reading muon trigger scalers with the DA of the muon trigger and transfer
[u/mrichter/AliRoot.git] / ITS / TestPreprocessorSSD.C
1 /* $Id$ */
2
3 // This class runs the test preprocessor
4 // It uses AliTestShuttle to simulate a full Shuttle process
5
6 void TestPreprocessorSSD()
7 {
8   // load library
9   gSystem->Load("libTestShuttle");
10
11   // initialize location of CDB
12   //  AliCDBManager::Instance()->SetDefaultStorage("local://${ALICE_ROOT}/SHUTTLE/TestShuttle/TestCDB");
13
14   AliTestShuttle::SetMainCDB("local://$ALICE_ROOT/OCDB/SHUTTLE/TestShuttle/TestCDB");
15   AliTestShuttle::SetMainRefStorage("local://$ALICE_ROOT/OCDB/SHUTTLE/TestShuttle/TestReference");
16
17   printf("Test OCDB storage Uri: %s\n", AliShuttleInterface::GetMainCDB().Data());
18   printf("Test Reference storage Uri: %s\n", AliShuttleInterface::GetMainRefStorage().Data());
19
20   // create AliTestShuttle instance
21   // The parameters are run, startTime, endTime
22
23   AliTestShuttle* shuttle = new AliTestShuttle(7, 0, 1);
24   shuttle->SetInputRunType("PEDESTAL_RUN");
25
26   shuttle->AddInputFile(AliTestShuttle::kDAQ, "SSD", "CALIBRATION", "LDC0", "ITSSSDda_LDC0.root");
27   shuttle->AddInputFile(AliTestShuttle::kDAQ, "SSD", "CALIBRATION", "LDC1", "ITSSSDda_LDC1.root");
28   shuttle->AddInputFile(AliTestShuttle::kDAQ, "SSD", "CALIBRATION", "LDC2", "ITSSSDda_LDC2.root");
29
30   // TODO(3)
31   // Create the preprocessor that should be tested, it registers itself automatically to the shuttle
32   AliPreprocessor *pp = new AliITSPreprocessorSSD(shuttle);
33
34   // Test the preprocessor
35   shuttle->Process();
36
37   
38   //
39   // Check the file which should have been created
40   AliCDBManager::Instance()->SetDefaultStorage("local://${ALICE_ROOT}/SHUTTLE/TestShuttle/TestCDB");  
41   AliCDBEntry* entry = AliCDBManager::Instance()->Get("ITS/Calib/NoiseSSD", 7);
42   if (!entry)
43   {
44     printf("The file is not there. Something went wrong.\n");
45     return;
46   }
47   
48
49 }
50