]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PHOS/testreconDigits.C
Loop variables declared once (HP)
[u/mrichter/AliRoot.git] / PHOS / testreconDigits.C
1 #include "AliPHOSDigitizer.h"
2 #include "AliPHOSGetter.h"
3 #include "TSystem.h"
4 #include "AliPHOSDigit.h"
5
6
7 void testreconDigits(Int_t nevent = 1, const char *config="testconfig.C")
8 { const Float_t maxDigits = 3489.41 ;
9   const Float_t widDigits = TMath::Sqrt(maxDigits) ;
10   AliPHOSDigitizer *d = new AliPHOSDigitizer("testPHOS.root","test suite");
11   AliPHOSGetter * gime = AliPHOSGetter::GetInstance() ;
12   d->ExecuteTask("deb"); 
13   Float_t nDigits = (Float_t)(gime->Digitizer()->GetDigitsInRun()) / gime->MaxEvent();
14   
15   if ( nDigits < maxDigits-widDigits || nDigits > maxDigits+widDigits ) {
16     cerr<<"__________________________________________________________________"<<endl;
17     cerr<<" "<<endl;
18     cerr<<"             MESS ==> Error detected in the Digits process. Sending error file to PHOS director."<<endl;
19     cerr<<"__________________________________________________________________"<<endl;
20    // gSystem->Exec("uuencode $ALICE_ROOT/PHOS/testPHOS.root testPHOS.root | mail -s 'PHOS INSTALLATION ERROR' schutz@in2p3.fr");
21   }
22  cerr<<"__________________________________________________________________"<<endl;
23   cerr<<" "<<endl;
24   cerr<<"             MESS ==> Digits process ended successfully."<<endl;
25   cerr<<"__________________________________________________________________"<<endl;
26 }
27