23TEST(_GTestCbmPixelHit, CheckStandardConstructor)
25 CbmPixelHit test {-1, 0., 0., 0., 0., 0., 0., 0., -1};
27 SCOPED_TRACE(
"CheckStandardConstructor");
28 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., 0., 0., 0., 0., 0.);
32TEST(_GTestCbmPixelHit, CheckStandardConstructorWithTime)
34 CbmPixelHit test {-1, 0., 0., 0., 0., 0., 0., 0., -1, -2., -2.};
36 SCOPED_TRACE(
"CheckStandardConstructorWithTime");
37 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -2., -2., 0., 0., 0., 0., 0.);
60TEST(_GTestCbmPixelHit, CheckStandardConstructorTVector3WithTime)
74 SCOPED_TRACE(
"CheckStandardConstructorWithTime");
75 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -2., -2., 0., 0., 0., 0., 0.);
79TEST(_GTestCbmPixelHit, CheckSetters)
83 SCOPED_TRACE(
"CheckSetters: Initial Test");
84 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., 0., 0., 0., 0., 0.);
89 SCOPED_TRACE(
"CheckSetters: SetX");
90 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., -11., 0., 0., 0., 0.);
95 SCOPED_TRACE(
"CheckSetters: SetDx");
96 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., -11., -12., 0., 0., 0.);
101 SCOPED_TRACE(
"CheckSetters: SetY");
102 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., -11., -12., -13., 0., 0.);
107 SCOPED_TRACE(
"CheckSetters: SetDy");
108 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., -11., -12., -13., -14., 0.);
113 SCOPED_TRACE(
"CheckSetters: SetDxy");
114 comparePixelHitDataMembers(test,
kPIXELHIT, 0., 0., -1, -1,
nullptr, -1., -1., -11., -12., -13., -14., -15.);
117 TVector3
pos {-21., -22., -23.};
120 SCOPED_TRACE(
"CheckSetters: SetPosition");
121 comparePixelHitDataMembers(test,
kPIXELHIT, -23., 0., -1, -1,
nullptr, -1., -1., -21., -12., -22., -14., -15.);
124 TVector3 poserror {-31., -32., -33.};
127 SCOPED_TRACE(
"CheckSetters: SetPosition");
128 comparePixelHitDataMembers(test,
kPIXELHIT, -23., -33., -1, -1,
nullptr, -1., -1., -21., -31., -22., -32., -15.);
133 EXPECT_FLOAT_EQ(pos1.X(),
pos.X());
134 EXPECT_FLOAT_EQ(pos1.Y(),
pos.Y());
135 EXPECT_FLOAT_EQ(pos1.Z(),
pos.Z());
139 EXPECT_FLOAT_EQ(poserror1.X(), poserror.X());
140 EXPECT_FLOAT_EQ(poserror1.Y(), poserror.Y());
141 EXPECT_FLOAT_EQ(poserror1.Z(), poserror.Z());
void comparePixelHitDataMembers(CbmPixelHit &test, HitType type, double z, double dz, int32_t refid, int32_t address, CbmMatch *match, double time, double errortime, double x, double dx, double y, double dy, double dxy)