Belle II Software  release-06-00-14
TrackFindingCDCTestWithTopology.cc
1 /**************************************************************************
2  * basf2 (Belle II Analysis Software Framework) *
3  * Author: The Belle II Collaboration *
4  * *
5  * See git log for contributors and copyright holders. *
6  * This file is licensed under LGPL-3.0, see LICENSE.md. *
7  **************************************************************************/
8 
9 #include <tracking/trackFindingCDC/testFixtures/TrackFindingCDCTestWithTopology.h>
10 
11 #include <tracking/trackFindingCDC/topology/CDCWireTopology.h>
12 #include <tracking/trackFindingCDC/topology/CDCGeometryLoader.h>
13 
14 #include <cmath>
15 
16 using namespace Belle2;
17 using namespace TrackFindingCDC;
18 
19 
21 {
24 
25  // Prepare the wires for the cdc track finders.
27 }
28 
30 {
32 }
33 
34 
35 
36 template<>
37 bool Belle2::TestHelpers::allNear<Vector3D>(const Vector3D& expected,
38  const Vector3D& actual,
39  double tolerance)
40 {
41  bool xNear = std::fabs(expected.x() - actual.x()) < tolerance;
42  bool yNear = std::fabs(expected.y() - actual.y()) < tolerance;
43  bool zNear = std::fabs(expected.z() - actual.z()) < tolerance;
44  return xNear and yNear and zNear;
45 }
static void closeDatabase()
Helper function to close and reset the database - only for tests offside the standard event processin...
static void loadDatabase()
Helper function to open the database - only for tests offside the standard event processing.
static CDCWireTopology & getInstance()
Getter for the singleton instance of the wire topology.
static void SetUpTestCase()
Implementation of hook method to setup the environment for all tests in this test case Unpacks the wi...
static void TearDownTestCase()
Implementation of hook method to clean up the environment for all tests in this test case.
A three dimensional vector.
Definition: Vector3D.h:32
double x() const
Getter for the x coordinate.
Definition: Vector3D.h:462
double y() const
Getter for the y coordinate.
Definition: Vector3D.h:474
double z() const
Getter for the z coordinate.
Definition: Vector3D.h:486
Abstract base class for different kinds of events.