OpenMesh
unittests_common.hh
1 #ifndef INCLUDE_UNITTESTS_COMMON_HH
2 #define INCLUDE_UNITTESTS_COMMON_HH
3 
4 #include <gtest/gtest.h>
5 
6 #include <OpenMesh/Core/Mesh/TriMesh_ArrayKernelT.hh>
7 #include <OpenMesh/Core/Mesh/PolyMesh_ArrayKernelT.hh>
8 
9 #include <OpenMesh/Core/IO/MeshIO.hh>
10 
11 #ifdef TEST_CUSTOM_TRAITS
12 #include <Unittests/unittests_common_customtraits.hh>
13 #elif defined(TEST_DOUBLE_TRAITS)
15 };
16 #else
18 };
19 #endif
20 
21 
23 
25 
26 /*
27  * Simple test setting.
28  */
29 
30 class OpenMeshBase : public testing::Test {
31 
32  protected:
33 
34  // This function is called before each test is run
35  virtual void SetUp() {
36 
37  // Do some initial stuff with the member data here...
38  }
39 
40  // This function is called after all tests are through
41  virtual void TearDown() {
42 
43  // Do some final stuff with the member data here...
44  }
45 
46  // This member will be accessible in all tests
47  Mesh mesh_;
48 };
49 
50 /*
51  * Simple test setting.
52  */
53 
54 class OpenMeshBasePoly : public testing::Test {
55 
56  protected:
57 
58  // This function is called before each test is run
59  virtual void SetUp() {
60 
61  // Do some initial stuff with the member data here...
62  }
63 
64  // This function is called after all tests are through
65  virtual void TearDown() {
66 
67  // Do some final stuff with the member data here...
68  }
69 
70  // This member will be accessible in all tests
71  PolyMesh mesh_;
72 };
73 
74 
75 
76 #endif // INCLUDE GUARD
Triangle mesh based on the ArrayKernel.
Definition: TriMesh_ArrayKernelT.hh:96
Polygonal mesh based on the ArrayKernel.
Definition: PolyMesh_ArrayKernelT.hh:96
Base class for all traits.
Definition: Traits.hh:122
Version of Default Traits that uses double precision for points and normals as well as floating point...
Definition: Traits.hh:164
Definition: unittests_common.hh:17
Definition: unittests_common.hh:30
Definition: unittests_common.hh:54

Project OpenMesh, ©  Visual Computing Institute, RWTH Aachen. Documentation generated using doxygen .