OpenMesh
Unittests/unittests_common.hh
00001 #ifndef INCLUDE_UNITTESTS_COMMON_HH
00002 #define INCLUDE_UNITTESTS_COMMON_HH
00003 
00004 #include <gtest/gtest.h>
00005 #include <OpenMesh/Core/IO/MeshIO.hh>
00006 
00007 #include <OpenMesh/Core/Mesh/TriMesh_ArrayKernelT.hh>
00008 
00009 struct CustomTraits : public OpenMesh::DefaultTraits {
00010 };
00011 
00012 typedef OpenMesh::TriMesh_ArrayKernelT<CustomTraits> Mesh;
00013 
00014 /*
00015  * Simple test setting.
00016  */
00017 
00018 class OpenMeshBase : public testing::Test {
00019 
00020     protected:
00021 
00022         // This function is called before each test is run
00023         virtual void SetUp() {
00024             
00025             // Do some initial stuff with the member data here...
00026         }
00027 
00028         // This function is called after all tests are through
00029         virtual void TearDown() {
00030 
00031             // Do some final stuff with the member data here...
00032         }
00033 
00034     // This member will be accessible in all tests
00035     Mesh mesh_;  
00036 };
00037 
00038 #endif // INCLUDE GUARD