CbmRoot
compareVertex.h
Go to the documentation of this file.
2  Double_t x,
3  Double_t y,
4  Double_t z,
5  Double_t chi2,
6  Int_t ndf,
7  Int_t ntracks,
8  Double_t* cov) {
9  Int_t retValInt {-111};
10  Double_t retValDouble {-111.};
11 
12  retValDouble = test.GetX();
13  EXPECT_FLOAT_EQ(x, retValDouble);
14 
15  retValDouble = test.GetY();
16  EXPECT_FLOAT_EQ(y, retValDouble);
17 
18  retValDouble = test.GetZ();
19  EXPECT_FLOAT_EQ(z, retValDouble);
20 
21  retValDouble = test.GetChi2();
22  EXPECT_FLOAT_EQ(chi2, retValDouble);
23 
24  retValInt = test.GetNDF();
25  EXPECT_EQ(ndf, retValInt);
26 
27  retValInt = test.GetNTracks();
28  EXPECT_EQ(ntracks, retValInt);
29 
30  if (cov) {
31  retValDouble = test.GetCovariance(0, 0);
32  EXPECT_FLOAT_EQ(cov[0], retValDouble);
33 
34  retValDouble = test.GetCovariance(0, 1);
35  EXPECT_FLOAT_EQ(cov[1], retValDouble);
36 
37  retValDouble = test.GetCovariance(0, 2);
38  EXPECT_FLOAT_EQ(cov[2], retValDouble);
39 
40  retValDouble = test.GetCovariance(1, 1);
41  EXPECT_FLOAT_EQ(cov[3], retValDouble);
42 
43  retValDouble = test.GetCovariance(1, 2);
44  EXPECT_FLOAT_EQ(cov[4], retValDouble);
45 
46  retValDouble = test.GetCovariance(2, 2);
47  EXPECT_FLOAT_EQ(cov[5], retValDouble);
48  }
49 }
CbmVertex::GetNTracks
Int_t GetNTracks() const
Definition: CbmVertex.h:73
CbmVertex::GetCovariance
Double_t GetCovariance(Int_t i, Int_t j) const
Definition: CbmVertex.cxx:118
CbmVertex::GetX
Double_t GetX() const
Definition: CbmVertex.h:68
CbmVertex::GetChi2
Double_t GetChi2() const
Definition: CbmVertex.h:71
CbmVertex
Definition: CbmVertex.h:26
CbmVertex::GetZ
Double_t GetZ() const
Definition: CbmVertex.h:70
CbmVertex::GetY
Double_t GetY() const
Definition: CbmVertex.h:69
x
Double_t x
Definition: CbmMvdSensorDigiToHitTask.cxx:68
y
Double_t y
Definition: CbmMvdSensorDigiToHitTask.cxx:68
CbmVertex::GetNDF
Int_t GetNDF() const
Definition: CbmVertex.h:72
compareVertexDataMembers
void compareVertexDataMembers(CbmVertex &test, Double_t x, Double_t y, Double_t z, Double_t chi2, Int_t ndf, Int_t ntracks, Double_t *cov)
Definition: compareVertex.h:1