[MOAB-dev] commit/MOAB: 77 new changesets

commits-noreply at bitbucket.org commits-noreply at bitbucket.org
Tue Mar 25 20:55:19 CDT 2014


77 new commits in MOAB:

https://bitbucket.org/fathomteam/moab/commits/c6acfd1636cc/
Changeset:   c6acfd1636cc
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Created a new file for basic tests on ReadCGM using a simple geometry. Old ReadCGM test filed renamed to reduce confusion.

Affected #:  2 files

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 7a2d07d..a79c84a 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -31,6 +31,7 @@ static const char input_cube[] = "cube.sat";
 #endif
 #endif
 
+
 void read_cube_test()
 {
   Core mb;

diff --git a/test/io/read_cgm_load_test.cpp b/test/io/read_cgm_load_test.cpp
index 5377220..9704ee7 100644
--- a/test/io/read_cgm_load_test.cpp
+++ b/test/io/read_cgm_load_test.cpp
@@ -43,7 +43,8 @@ void read_multiple_test()
   
 int main(int /* argc */, char** /* argv */)
 {
-  int result = RUN_TEST( read_multiple_test );
+  
+  int result = RUN_TEST( read_multiple_test ) ;
 
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/4d060258cf98/
Changeset:   4d060258cf98
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Removed unused tag_get_handle call in read_cgm testing

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index a79c84a..301881d 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -38,10 +38,6 @@ void read_cube_test()
  
   ErrorCode rval = mb.load_file(input_cube); CHECK_ERR(rval);
 
-  Tag geom_tag;
-
-  rval = mb.tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER,
-                                  geom_tag, MB_TAG_SPARSE|MB_TAG_CREAT); 
   CHECK_ERR(rval);
    
   int number_of_tris;


https://bitbucket.org/fathomteam/moab/commits/e72329531d60/
Changeset:   e72329531d60
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Attempt at fixing the problem with loading a file multiple times in clean MOAB instances.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 301881d..e0f7a3b 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -31,23 +31,32 @@ static const char input_cube[] = "cube.sat";
 #endif
 #endif
 
+void read_file( Interface* moab, const char* input_file );
+void read_cube_test();
 
-void read_cube_test()
-{
-  Core mb;
- 
-  ErrorCode rval = mb.load_file(input_cube); CHECK_ERR(rval);
 
+void read_file( Interface* moab, const char* input_file )
+{
+  ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR(rval);
+}
+
+void read_cube_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  mb->delete_mesh();
+  read_file( mb, input_cube );
    
   int number_of_tris;
 
-  rval = mb.get_number_entities_by_type(0, MBTRI , number_of_tris);
+  rval = mb->get_number_entities_by_type(0, MBTRI , number_of_tris);
   std::cout << "Number of Triangles = " << number_of_tris << std::endl;
   CHECK_ERR(rval);
 
   int number_of_vertices;
-  rval = mb.get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
+  rval = mb->get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
   CHECK_ERR(rval);
 
 
@@ -55,13 +64,15 @@ void read_cube_test()
    
   if( number_of_vertices !=8) rval = MB_FAILURE; CHECK_ERR(rval);
 
+
 }
   
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
-  
+
+  result += RUN_TEST( read_cube_test );
   result += RUN_TEST( read_cube_test );
-      
+
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/48e1819a1808/
Changeset:   48e1819a1808
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     More changes to decypher how to create new moab instances.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index e0f7a3b..b4dea11 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -46,7 +46,6 @@ void read_cube_test()
   ErrorCode rval;
   Core moab;
   Interface* mb = &moab;
-  mb->delete_mesh();
   read_file( mb, input_cube );
    
   int number_of_tris;
@@ -66,12 +65,57 @@ void read_cube_test()
 
 
 }
+
+void delete_mesh_test()
+{
+ Core moab;
+ Interface* mb = &moab;
+ read_file( mb, input_cube );
+
+ ErrorCode rval; 
+
+ Tag geom_tag; 
+
+ rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+ CHECK_ERR(rval);
+
+ Range geom_sets[4];
+
+ for(unsigned dim=0; dim<4; dim++) 
+ {
+	void *val[] = {&dim};
+	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, geom_sets[dim] );
+        CHECK_ERR(rval); 
+
+        if( geom_sets[dim].size() == 0 ) std::cout << "Warning: No geom sets to begin with" << std::endl;
+
+ }
+
+ mb->delete_mesh();
+
+ Range geom_sets_after[4];
+ for(unsigned dim=0; dim<4; dim++) 
+ {
+	void *val_after[] = {&dim};
+	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val_after, 1, geom_sets_after[dim] );
+        CHECK_ERR(rval); 
+
+        if( 0 != geom_sets_after[dim].size() ) rval = MB_FAILURE;
+
+        CHECK_ERR(rval);
+ }
+
+}
   
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_test );
+  result += RUN_TEST( read_cube_test );  
+  result += RUN_TEST( delete_mesh_test );
   result += RUN_TEST( read_cube_test );
 
   return result;


https://bitbucket.org/fathomteam/moab/commits/c4c630513af8/
Changeset:   c4c630513af8
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Separated test for cube verts and test for cube triangles. Updated method of value comparison.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index b4dea11..5dd4615 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -41,7 +41,22 @@ void read_file( Interface* moab, const char* input_file )
   CHECK_ERR(rval);
 }
 
-void read_cube_test()
+void read_cube_verts_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  int number_of_vertices;
+  rval = mb->get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
+  CHECK_ERR(rval);
+ 
+  CHECK_EQUAL( 8, number_of_vertices);
+}
+
+
+void read_cube_tris_test()
 {
   ErrorCode rval;
   Core moab;
@@ -54,18 +69,20 @@ void read_cube_test()
   std::cout << "Number of Triangles = " << number_of_tris << std::endl;
   CHECK_ERR(rval);
 
-  int number_of_vertices;
-  rval = mb->get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
-  CHECK_ERR(rval);
-
+  CHECK_EQUAL( 12, number_of_tris);  
 
-  if( number_of_tris != 12) rval = MB_FAILURE; CHECK_ERR(rval);
-   
-  if( number_of_vertices !=8) rval = MB_FAILURE; CHECK_ERR(rval);
+}
+ 
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
 
+  result += RUN_TEST( read_cube_tris_test );  
 
+  return result;
 }
 
+
 void delete_mesh_test()
 {
  Core moab;
@@ -109,14 +126,4 @@ void delete_mesh_test()
  }
 
 }
-  
-int main(int /* argc */, char** /* argv */)
-{
-  int result = 0;
-
-  result += RUN_TEST( read_cube_test );  
-  result += RUN_TEST( delete_mesh_test );
-  result += RUN_TEST( read_cube_test );
-
-  return result;
-}
+ 


https://bitbucket.org/fathomteam/moab/commits/badf6a41d71d/
Changeset:   badf6a41d71d
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Added multiple new tests for the correct number of geometric entities in read_cgm_basic_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 5dd4615..d487a48 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -32,7 +32,6 @@ static const char input_cube[] = "cube.sat";
 #endif
 
 void read_file( Interface* moab, const char* input_file );
-void read_cube_test();
 
 
 void read_file( Interface* moab, const char* input_file )
@@ -72,12 +71,90 @@ void read_cube_tris_test()
   CHECK_EQUAL( 12, number_of_tris);  
 
 }
- 
+
+void read_cube_curves_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  Tag geom_tag;
+
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  Range curves;
+  int dim = 1;
+  void *val[] = {&dim};
+  int number_of_curves;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_curves );
+  CHECK_ERR(rval);
+  
+
+  CHECK_EQUAL( 12, number_of_curves);  
+
+} 
+
+void read_cube_surfs_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  Tag geom_tag;
+
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  Range curves;
+  int dim = 2;
+  void *val[] = {&dim};
+  int number_of_surfs;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_surfs );
+  CHECK_ERR(rval);
+  
+
+  CHECK_EQUAL( 6, number_of_surfs);  
+
+}
+
+void read_cube_vols_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  Tag geom_tag;
+
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  Range curves;
+  int dim = 3;
+  void *val[] = {&dim};
+  int number_of_vols;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_vols );
+  CHECK_ERR(rval);
+  
+
+  CHECK_EQUAL( 1, number_of_vols);  
+
+}
+
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_tris_test );  
+  result += RUN_TEST( read_cube_vols_test );  
 
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/3ce6611b059b/
Changeset:   3ce6611b059b
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Added a function to verify that mesh vertices are in the correct locations.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index d487a48..94e6f7c 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -150,11 +150,81 @@ void read_cube_vols_test()
 
 }
 
+void read_cube_vertex_pos_test()
+{
+  ErrorCode rval;
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //First check that the correct number of vertices are present
+  int number_of_verts;
+  rval = mb->get_number_entities_by_type( 0 , MBVERTEX , number_of_verts);
+  CHECK_ERR(rval);
+
+  CHECK_EQUAL(8, number_of_verts);
+
+  //Retrieve all vertex handles from the mesh
+  Range verts;
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts);
+  CHECK_ERR(rval);
+
+  //Get the vertex coordinates
+  double x[verts.size()];
+  double y[verts.size()];
+  double z[verts.size()];
+  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0]);
+  CHECK_ERR(rval);
+
+  //Check against known locations of the vertices
+
+  // Vertex 1
+  CHECK_EQUAL( x[0], 5);
+  CHECK_EQUAL( y[0], -5);
+  CHECK_EQUAL( z[0], 5);
+
+  // Vertex 2
+  CHECK_EQUAL( x[1], 5);
+  CHECK_EQUAL( y[1], 5);
+  CHECK_EQUAL( z[1], 5);
+
+  // Vertex 3
+  CHECK_EQUAL( x[2], -5);
+  CHECK_EQUAL( y[2], 5);
+  CHECK_EQUAL( z[2], 5);
+
+  // Vertex 4
+  CHECK_EQUAL( x[3], -5);
+  CHECK_EQUAL( y[3], -5);
+  CHECK_EQUAL( z[3], 5);
+
+  // Vertex 5
+  CHECK_EQUAL( x[4], 5);
+  CHECK_EQUAL( y[4], 5);
+  CHECK_EQUAL( z[4], -5);
+
+  // Vertex 6
+  CHECK_EQUAL( x[5], 5);
+  CHECK_EQUAL( y[5], -5);
+  CHECK_EQUAL( z[5], -5);
+
+  // Vertex 7
+  CHECK_EQUAL( x[6], -5);
+  CHECK_EQUAL( y[6], -5);
+  CHECK_EQUAL( z[6], -5);
+
+  // Vertex 8
+  CHECK_EQUAL( x[7], -5);
+  CHECK_EQUAL( y[7], 5);
+  CHECK_EQUAL( z[7], -5);
+
+}
+
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_vols_test );  
+  result += RUN_TEST( read_cube_vertex_pos_test );  
 
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/44ee45e7b20d/
Changeset:   44ee45e7b20d
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:00
Summary:     Added some comments to read_cgm_basic_test.cpp for clarity.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 94e6f7c..1f7c479 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -43,6 +43,7 @@ void read_file( Interface* moab, const char* input_file )
 void read_cube_verts_test()
 {
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
@@ -58,6 +59,7 @@ void read_cube_verts_test()
 void read_cube_tris_test()
 {
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
@@ -75,6 +77,7 @@ void read_cube_tris_test()
 void read_cube_curves_test()
 {
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
@@ -92,7 +95,6 @@ void read_cube_curves_test()
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
   CHECK_ERR(rval);
-  
 
   CHECK_EQUAL( 12, number_of_curves);  
 
@@ -101,6 +103,7 @@ void read_cube_curves_test()
 void read_cube_surfs_test()
 {
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
@@ -127,12 +130,12 @@ void read_cube_surfs_test()
 void read_cube_vols_test()
 {
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
    
   Tag geom_tag;
-
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
 				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
@@ -152,7 +155,9 @@ void read_cube_vols_test()
 
 void read_cube_vertex_pos_test()
 {
+  
   ErrorCode rval;
+  //Open the test file
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );


https://bitbucket.org/fathomteam/moab/commits/ccc0b4a7216b/
Changeset:   ccc0b4a7216b
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Restructured the read_cgm_basic_test file. Added comments for clarity.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 1f7c479..06c54ab 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -31,8 +31,29 @@ static const char input_cube[] = "cube.sat";
 #endif
 #endif
 
+// Function used to load the test file
 void read_file( Interface* moab, const char* input_file );
 
+// List of tests in this file
+void read_cube_verts_test();
+void read_cube_curves_test();
+void read_cube_surfs_test();
+void read_cube_vols_test();
+void read_cube_vertes_pos_test();
+void read_cube_curve_senses_test();
+void delete_mesh_test();
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+
+  result += RUN_TEST( read_cube_curve_senses_test );  
+
+  return result;
+}
+
+
 
 void read_file( Interface* moab, const char* input_file )
 {
@@ -225,16 +246,6 @@ void read_cube_vertex_pos_test()
 
 }
 
-int main(int /* argc */, char** /* argv */)
-{
-  int result = 0;
-
-  result += RUN_TEST( read_cube_vertex_pos_test );  
-
-  return result;
-}
-
-
 void delete_mesh_test()
 {
  Core moab;


https://bitbucket.org/fathomteam/moab/commits/d9ac9e301790/
Changeset:   d9ac9e301790
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Created a new file for testing the loading of sense data with READ_CGM.

This was done for a simple cube geometry. Cleanup of the code is needed.

Affected #:  2 files

diff --git a/test/io/Makefile.am b/test/io/Makefile.am
index 6cf835a..31049a1 100644
--- a/test/io/Makefile.am
+++ b/test/io/Makefile.am
@@ -25,7 +25,7 @@ else
 endif
 
 if HAVE_CGM
-  CGM_TEST = read_cgm_load_test read_cgm_basic_test
+  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test
 else
   CGM_TEST = 
 endif

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
new file mode 100644
index 0000000..f42abed
--- /dev/null
+++ b/test/io/read_cgm_senses_test.cpp
@@ -0,0 +1,233 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "moab/GeomTopoTool.hpp"
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+#else
+static const char input_cube[] = "/io/cube.sat";
+#endif
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// Functions containing known sense data
+void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+
+// Functions used to compare sense information found in 
+// the model to reference information
+
+void check_curve_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses);
+
+//Function used to get id's from entity handles
+int geom_id_by_handle( Interface* moab, const EntityHandle set );
+
+// List of tests in this file
+void read_cube_curve_senses_test();
+void delete_mesh_test();
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+
+  result += RUN_TEST( read_cube_curve_senses_test );  
+
+  return result;
+}
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}
+
+void read_cube_curve_senses_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+  
+  //Get all curve handles
+  Tag geom_tag;
+
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  // Check that the proper number of curves exist
+
+  int dim = 1;
+  void *val[] = {&dim};
+  int number_of_curves;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_curves );
+  CHECK_ERR(rval);
+  CHECK_EQUAL(12 , number_of_curves);
+  
+  // Get curve handles
+  Range curves;
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, curves );
+  CHECK_ERR(rval);
+
+  // Establish GeomTopoTool instance needed to get curve data 
+  moab::GeomTopoTool gt(mb, false);  
+  std::vector<EntityHandle> surfs;
+  std::vector<int> senses;  
+  std::vector<int> known_surf_ids;
+  std::vector<int> known_senses;
+
+for(unsigned int i = 0; i < curves.size() ; i++)
+  {
+  
+  surfs.clear();
+  senses.clear();
+  //Curve 1
+  gt.get_senses( curves[i], surfs, senses);
+  CHECK_ERR(rval);
+
+  //Load known curve-sense data
+
+   known_surf_ids.clear();
+   known_senses.clear();
+   load_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+
+   check_curve_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
+  }
+
+}
+
+
+int geom_id_by_handle( Interface* moab, const EntityHandle set ) {
+    
+ErrorCode rval;
+    Tag id_tag;
+    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE);
+    assert(MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result);                       
+    int id;
+    rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
+    assert(MB_SUCCESS == result);                           
+    return id;
+ }
+
+void check_curve_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses)
+{
+  
+  std::vector<int> wrt_ent_ids;
+  for( unsigned int i=0 ; i<wrt_ents.size() ; i++)
+  {
+      wrt_ent_ids.push_back(geom_id_by_handle(moab, wrt_ents[i]));
+  }
+
+  for (unsigned int i=0; i< wrt_ent_ids.size() ; i++)
+  {
+     for(unsigned int j=0; j< known_wrt_ids.size(); j++)
+     {
+       if(wrt_ent_ids[i] == known_wrt_ids [j])
+         {
+          CHECK_EQUAL(senses[i],known_senses[j]);
+          known_wrt_ids.erase(known_wrt_ids.begin()+j);
+          known_senses.erase(known_senses.begin()+j);
+         }
+     }
+  }
+
+  int leftovers = known_wrt_ids.size();
+
+  CHECK_EQUAL(leftovers, 0 );
+
+}
+void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out ){
+
+  int curve_id = geom_id_by_handle( moab, curve);
+
+  std::cout << curve_id << std::endl;
+
+
+  switch(curve_id)
+  {
+    case 1:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(6);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 2:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(5);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 3:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(4);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 4:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(3);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 5:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(6);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 6:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(3);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 7:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(4);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 8:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(5);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 9:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(4);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 10:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(6);
+          senses_out.push_back(-1); senses_out.push_back(1);
+
+    break;
+    case 11:
+          surf_ids_out.push_back(4); surf_ids_out.push_back(5);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+    case 12:
+          surf_ids_out.push_back(5); surf_ids_out.push_back(6);
+          senses_out.push_back(1); senses_out.push_back(-1);
+
+    break;
+  } 
+
+}
+


https://bitbucket.org/fathomteam/moab/commits/e4945426e8bb/
Changeset:   e4945426e8bb
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Removed curve sense test from read_cgm_basic_test.

This was still there from before the creation of the new file read_cgm_senses_test where this function now lives.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 06c54ab..64ee56b 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -40,7 +40,6 @@ void read_cube_curves_test();
 void read_cube_surfs_test();
 void read_cube_vols_test();
 void read_cube_vertes_pos_test();
-void read_cube_curve_senses_test();
 void delete_mesh_test();
 
 
@@ -48,7 +47,7 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_curve_senses_test );  
+  result += RUN_TEST( read_cube_verts_test );  
 
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/b25147998ab5/
Changeset:   b25147998ab5
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Added a new test to check the sense loading of a simple cube geometry using READ_CGM.

Again, this new function read_cgm_surf_senses_test along with read_cgm_curve_senses_test needs some cleanup.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index f42abed..fcc2281 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -28,11 +28,11 @@ void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-
+void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 // Functions used to compare sense information found in 
 // the model to reference information
 
-void check_curve_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
                              std::vector<int> known_wrt_ids, std::vector<int> known_senses);
 
 //Function used to get id's from entity handles
@@ -40,6 +40,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set );
 
 // List of tests in this file
 void read_cube_curve_senses_test();
+void read_cube_surf_senses_test();
 void delete_mesh_test();
 
 
@@ -47,7 +48,7 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_curve_senses_test );  
+  result += RUN_TEST( read_cube_surf_senses_test );  
 
   return result;
 }
@@ -112,7 +113,7 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    known_senses.clear();
    load_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
 
-   check_curve_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
+   check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
   }
 
 }
@@ -130,7 +131,7 @@ ErrorCode rval;
     return id;
  }
 
-void check_curve_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
                              std::vector<int> known_wrt_ids, std::vector<int> known_senses)
 {
   
@@ -158,6 +159,7 @@ void check_curve_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents
   CHECK_EQUAL(leftovers, 0 );
 
 }
+
 void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out ){
 
   int curve_id = geom_id_by_handle( moab, curve);
@@ -231,3 +233,113 @@ void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int
 
 }
 
+
+
+
+///SURFACE SENSE CHECKING
+
+void read_cube_surf_senses_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+  
+  //Get all curve handles
+  Tag geom_tag;
+
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  // Check that the proper number of curves exist
+
+  int dim = 2;
+  void *val[] = {&dim};
+  int number_of_curves;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_curves );
+  CHECK_ERR(rval);
+  CHECK_EQUAL(6 , number_of_curves);
+  
+  // Get curve handles
+  Range surfs;
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, surfs );
+  CHECK_ERR(rval);
+
+  // Establish GeomTopoTool instance needed to get curve data 
+  moab::GeomTopoTool gt(mb, false);  
+  std::vector<EntityHandle> vols;
+  std::vector<int> senses;  
+  std::vector<int> known_vol_ids;
+  std::vector<int> known_senses;
+
+for(unsigned int i = 0; i < surfs.size() ; i++)
+  {
+  
+  vols.clear();
+  senses.clear();
+  //Curve 1
+  gt.get_senses( surfs[i], vols, senses);
+  CHECK_ERR(rval);
+
+  //Load known curve-sense data
+
+   known_vol_ids.clear();
+   known_senses.clear();
+   load_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+
+   check_sense_data( mb, vols, senses, known_vol_ids, known_senses);
+  }
+
+}
+
+void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+
+  int surf_id = geom_id_by_handle( moab, surf);
+
+
+
+
+  switch(surf_id)
+  {
+    case 1:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+    case 2:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+
+    case 3:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+    case 4:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+    case 5:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+    case 6:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(1); 
+
+    break;
+   }
+
+}
+
+
+
+


https://bitbucket.org/fathomteam/moab/commits/63ce05829f9d/
Changeset:   63ce05829f9d
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Cleaned up read_cgm_basic_tests.cpp.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 64ee56b..c5e4283 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -127,11 +127,11 @@ void read_cube_surfs_test()
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
-   
+  
+  //Get geometry tag for pulling curve data from the mesh 
   Tag geom_tag;
-
-  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
-				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
   
   Range curves;
@@ -140,10 +140,10 @@ void read_cube_surfs_test()
   int number_of_surfs;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_surfs );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
   
 
-  CHECK_EQUAL( 6, number_of_surfs);  
+  CHECK_EQUAL( 6, number_of_surfs );  
 
 }
 
@@ -154,11 +154,12 @@ void read_cube_vols_test()
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
-   
+  
+  //Get geometry tag for pulling curve data from the mesh 
   Tag geom_tag;
-  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
-				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR(rval);
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR( rval );
   
   Range curves;
   int dim = 3;
@@ -166,10 +167,10 @@ void read_cube_vols_test()
   int number_of_vols;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_vols );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
   
 
-  CHECK_EQUAL( 1, number_of_vols);  
+  CHECK_EQUAL( 1, number_of_vols );
 
 }
 
@@ -184,64 +185,64 @@ void read_cube_vertex_pos_test()
 
   //First check that the correct number of vertices are present
   int number_of_verts;
-  rval = mb->get_number_entities_by_type( 0 , MBVERTEX , number_of_verts);
-  CHECK_ERR(rval);
+  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
+  CHECK_ERR( rval );
 
-  CHECK_EQUAL(8, number_of_verts);
+  CHECK_EQUAL( 8, number_of_verts );
 
   //Retrieve all vertex handles from the mesh
   Range verts;
-  rval = mb->get_entities_by_type( 0, MBVERTEX, verts);
-  CHECK_ERR(rval);
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
+  CHECK_ERR( rval );
 
   //Get the vertex coordinates
   double x[verts.size()];
   double y[verts.size()];
   double z[verts.size()];
-  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0]);
-  CHECK_ERR(rval);
+  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
+  CHECK_ERR( rval );
 
   //Check against known locations of the vertices
 
   // Vertex 1
-  CHECK_EQUAL( x[0], 5);
-  CHECK_EQUAL( y[0], -5);
-  CHECK_EQUAL( z[0], 5);
+  CHECK_EQUAL( x[0], 5  );
+  CHECK_EQUAL( y[0], -5 );
+  CHECK_EQUAL( z[0], 5  );
 
   // Vertex 2
-  CHECK_EQUAL( x[1], 5);
-  CHECK_EQUAL( y[1], 5);
-  CHECK_EQUAL( z[1], 5);
+  CHECK_EQUAL( x[1], 5  );
+  CHECK_EQUAL( y[1], 5  );
+  CHECK_EQUAL( z[1], 5  );
 
   // Vertex 3
-  CHECK_EQUAL( x[2], -5);
-  CHECK_EQUAL( y[2], 5);
-  CHECK_EQUAL( z[2], 5);
+  CHECK_EQUAL( x[2], -5 );
+  CHECK_EQUAL( y[2], 5  );
+  CHECK_EQUAL( z[2], 5  );
 
   // Vertex 4
-  CHECK_EQUAL( x[3], -5);
-  CHECK_EQUAL( y[3], -5);
-  CHECK_EQUAL( z[3], 5);
+  CHECK_EQUAL( x[3], -5 );
+  CHECK_EQUAL( y[3], -5 );
+  CHECK_EQUAL( z[3], 5  );
 
   // Vertex 5
-  CHECK_EQUAL( x[4], 5);
-  CHECK_EQUAL( y[4], 5);
-  CHECK_EQUAL( z[4], -5);
+  CHECK_EQUAL( x[4], 5  );
+  CHECK_EQUAL( y[4], 5  );
+  CHECK_EQUAL( z[4], -5 );
 
   // Vertex 6
-  CHECK_EQUAL( x[5], 5);
-  CHECK_EQUAL( y[5], -5);
-  CHECK_EQUAL( z[5], -5);
+  CHECK_EQUAL( x[5], 5  );
+  CHECK_EQUAL( y[5], -5 );
+  CHECK_EQUAL( z[5], -5 );
 
   // Vertex 7
-  CHECK_EQUAL( x[6], -5);
-  CHECK_EQUAL( y[6], -5);
-  CHECK_EQUAL( z[6], -5);
+  CHECK_EQUAL( x[6], -5 );
+  CHECK_EQUAL( y[6], -5 );
+  CHECK_EQUAL( z[6], -5 );
 
   // Vertex 8
-  CHECK_EQUAL( x[7], -5);
-  CHECK_EQUAL( y[7], 5);
-  CHECK_EQUAL( z[7], -5);
+  CHECK_EQUAL( x[7], -5 );
+  CHECK_EQUAL( y[7], 5  );
+  CHECK_EQUAL( z[7], -5 );
 
 }
 
@@ -253,10 +254,10 @@ void delete_mesh_test()
 
  ErrorCode rval; 
 
+ //Get geometry tag for pulling curve data from the mesh
  Tag geom_tag; 
-
- rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
-				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+ rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                            geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
  CHECK_ERR(rval);
 
  Range geom_sets[4];
@@ -266,7 +267,7 @@ void delete_mesh_test()
 	void *val[] = {&dim};
 	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, geom_sets[dim] );
-        CHECK_ERR(rval); 
+        CHECK_ERR( rval ); 
 
         if( geom_sets[dim].size() == 0 ) std::cout << "Warning: No geom sets to begin with" << std::endl;
 
@@ -280,11 +281,11 @@ void delete_mesh_test()
 	void *val_after[] = {&dim};
 	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val_after, 1, geom_sets_after[dim] );
-        CHECK_ERR(rval); 
+        CHECK_ERR( rval ); 
 
         if( 0 != geom_sets_after[dim].size() ) rval = MB_FAILURE;
 
-        CHECK_ERR(rval);
+        CHECK_ERR( rval );
  }
 
 }


https://bitbucket.org/fathomteam/moab/commits/e155ae5cdc78/
Changeset:   e155ae5cdc78
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:49:01
Summary:     Clean up of read_cgm_senses_test.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index fcc2281..aa11cae 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -33,7 +33,7 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
 // the model to reference information
 
 void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
-                             std::vector<int> known_wrt_ids, std::vector<int> known_senses);
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses );
 
 //Function used to get id's from entity handles
 int geom_id_by_handle( Interface* moab, const EntityHandle set );
@@ -57,7 +57,7 @@ int main(int /* argc */, char** /* argv */)
 void read_file( Interface* moab, const char* input_file )
 {
   ErrorCode rval = moab->load_file( input_file );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
 }
 
 void read_cube_curve_senses_test()
@@ -73,7 +73,7 @@ void read_cube_curve_senses_test()
 
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
 				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
   
   // Check that the proper number of curves exist
 
@@ -82,17 +82,17 @@ void read_cube_curve_senses_test()
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
-  CHECK_ERR(rval);
-  CHECK_EQUAL(12 , number_of_curves);
+  CHECK_ERR( rval );
+  CHECK_EQUAL( 12 , number_of_curves );
   
   // Get curve handles
   Range curves;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, curves );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
 
   // Establish GeomTopoTool instance needed to get curve data 
-  moab::GeomTopoTool gt(mb, false);  
+  moab::GeomTopoTool gt( mb, false );  
   std::vector<EntityHandle> surfs;
   std::vector<int> senses;  
   std::vector<int> known_surf_ids;
@@ -100,17 +100,18 @@ void read_cube_curve_senses_test()
 
 for(unsigned int i = 0; i < curves.size() ; i++)
   {
-  
-  surfs.clear();
-  senses.clear();
-  //Curve 1
-  gt.get_senses( curves[i], surfs, senses);
-  CHECK_ERR(rval);
 
-  //Load known curve-sense data
+   //Clean data from previous curve
+   surfs.clear();
+   senses.clear();
+   //Get sense info for the current curve
+   gt.get_senses( curves[i], surfs, senses);
+   CHECK_ERR(rval);
 
+   //Clear reference data from previous curve
    known_surf_ids.clear();
    known_senses.clear();
+   //Load known curve-sense data
    load_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
 
    check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
@@ -119,52 +120,58 @@ for(unsigned int i = 0; i < curves.size() ; i++)
 }
 
 
-int geom_id_by_handle( Interface* moab, const EntityHandle set ) {
+int geom_id_by_handle( Interface* moab, const EntityHandle set )
+{
     
-ErrorCode rval;
+    ErrorCode rval;
+
     Tag id_tag;
-    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE);
-    assert(MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result);                       
+    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
+    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+                      
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
-    assert(MB_SUCCESS == result);                           
+    CHECK_ERR( rval );                        
     return id;
  }
 
 void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
-                             std::vector<int> known_wrt_ids, std::vector<int> known_senses)
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses )
 {
   
+  //Get ID's of the wrt entities
   std::vector<int> wrt_ent_ids;
-  for( unsigned int i=0 ; i<wrt_ents.size() ; i++)
+  for( unsigned int i=0 ; i<wrt_ents.size() ; i++ )
   {
-      wrt_ent_ids.push_back(geom_id_by_handle(moab, wrt_ents[i]));
+      wrt_ent_ids.push_back( geom_id_by_handle( moab, wrt_ents[i] ));
   }
 
-  for (unsigned int i=0; i< wrt_ent_ids.size() ; i++)
+  for ( unsigned int i=0; i< wrt_ent_ids.size() ; i++ )
   {
-     for(unsigned int j=0; j< known_wrt_ids.size(); j++)
+     for( unsigned int j=0; j< known_wrt_ids.size(); j++ )
      {
-       if(wrt_ent_ids[i] == known_wrt_ids [j])
+       if( wrt_ent_ids[i] == known_wrt_ids [j] )
          {
-          CHECK_EQUAL(senses[i],known_senses[j]);
-          known_wrt_ids.erase(known_wrt_ids.begin()+j);
-          known_senses.erase(known_senses.begin()+j);
+          // Make sure the senses of the matching wrt entities
+          // are correct
+          CHECK_EQUAL( senses[i],known_senses[j] );
+          //Once a wrt entity is matched with a known entity,
+          // remove it from the list
+          known_wrt_ids.erase( known_wrt_ids.begin()+j );
+          known_senses.erase( known_senses.begin()+j );
          }
      }
   }
 
+  // After both loops are complete, known_wrt_ents should be empty 
   int leftovers = known_wrt_ids.size();
-
-  CHECK_EQUAL(leftovers, 0 );
+  CHECK_EQUAL( leftovers, 0 );
 
 }
 
 void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out ){
 
-  int curve_id = geom_id_by_handle( moab, curve);
-
-  std::cout << curve_id << std::endl;
+  int curve_id = geom_id_by_handle( moab, curve );
 
 
   switch(curve_id)
@@ -233,11 +240,7 @@ void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int
 
 }
 
-
-
-
 ///SURFACE SENSE CHECKING
-
 void read_cube_surf_senses_test()
 {
   ErrorCode rval;
@@ -246,62 +249,59 @@ void read_cube_surf_senses_test()
   Interface* mb = &moab;
   read_file( mb, input_cube );
   
-  //Get all curve handles
+  //Get geometry tag for gathering surface information from the mesh
   Tag geom_tag;
-
-  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
-				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR(rval);
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR( rval );
   
   // Check that the proper number of curves exist
-
   int dim = 2;
   void *val[] = {&dim};
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
-  CHECK_ERR(rval);
-  CHECK_EQUAL(6 , number_of_curves);
+  CHECK_ERR( rval );
+  CHECK_EQUAL( 6, number_of_curves );
   
   // Get curve handles
   Range surfs;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, surfs );
-  CHECK_ERR(rval);
+  CHECK_ERR( rval );
 
   // Establish GeomTopoTool instance needed to get curve data 
-  moab::GeomTopoTool gt(mb, false);  
+  moab::GeomTopoTool gt( mb, false );  
   std::vector<EntityHandle> vols;
   std::vector<int> senses;  
   std::vector<int> known_vol_ids;
   std::vector<int> known_senses;
 
-for(unsigned int i = 0; i < surfs.size() ; i++)
+for( unsigned int i = 0; i < surfs.size() ; i++ )
   {
-  
-  vols.clear();
-  senses.clear();
-  //Curve 1
-  gt.get_senses( surfs[i], vols, senses);
-  CHECK_ERR(rval);
-
-  //Load known curve-sense data
-
+   //Clean data from previous surface
+   vols.clear();
+   senses.clear();
+   // Get sense information for the current
+   // surface from the mesh
+   gt.get_senses( surfs[i], vols, senses);
+   CHECK_ERR(rval);
+
+   //Load known curve-sense data
    known_vol_ids.clear();
    known_senses.clear();
    load_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
-
+   // Check sense information from the loaded mesh against 
+   // reference sense information
    check_sense_data( mb, vols, senses, known_vol_ids, known_senses);
+
   }
 
 }
 
 void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
-  int surf_id = geom_id_by_handle( moab, surf);
-
-
-
+  int surf_id = geom_id_by_handle( moab, surf );
 
   switch(surf_id)
   {
@@ -329,17 +329,12 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
     case 5:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
-
     break;
     case 6:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
-
     break;
    }
 
 }
 
-
-
-


https://bitbucket.org/fathomteam/moab/commits/e4dc3ac0d25c/
Changeset:   e4dc3ac0d25c
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:50:45
Summary:     Added cgm flags to read_cgm_basic_test

Affected #:  2 files

diff --git a/src/io/ReadCGM.cpp b/src/io/ReadCGM.cpp
index bb9eb9a..e854a2e 100644
--- a/src/io/ReadCGM.cpp
+++ b/src/io/ReadCGM.cpp
@@ -16,7 +16,7 @@
 #pragma warning(disable:4786)
 #endif
 
-#include "cgm_version.h"
+//#include "cgm_version.h"
 #include "GeometryQueryTool.hpp"
 #include "ModelQueryEngine.hpp"
 #include "RefEntityName.hpp"

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index c5e4283..de5d7e1 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -8,6 +8,8 @@
 #include "Internals.hpp"
 #include "moab/Core.hpp"
 #include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
 
 using namespace moab;
 
@@ -56,6 +58,8 @@ int main(int /* argc */, char** /* argv */)
 
 void read_file( Interface* moab, const char* input_file )
 {
+  InitCGMA::initialize_cgma();
+
   ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR(rval);
 }


https://bitbucket.org/fathomteam/moab/commits/c4f6901e62c0/
Changeset:   c4f6901e62c0
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:50:45
Summary:     Finished fix for building ReadCGM tests with linked CGM libs.

Affected #:  3 files

diff --git a/test/io/Makefile.am b/test/io/Makefile.am
index 31049a1..4389075 100644
--- a/test/io/Makefile.am
+++ b/test/io/Makefile.am
@@ -73,7 +73,9 @@ ccmio_test_SOURCES = $(srcdir)/../TestUtil.hpp ccmio_test.cpp
 read_cgm_load_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_load_test.cpp
 read_cgm_load_test_CXXFLAGS = $(CGM_CPPFLAGS)  $(CXXFLAGS)
 read_cgm_basic_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_basic_test.cpp
-read_cgm_basic_test_CXXFLAGS = $(CGM_CPPFLAGS)  $(CXXFLAGS)
+read_cgm_basic_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_senses_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_senses_test.cpp
+read_cgm_senses_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 readutil_test_SOURCES = $(srcdir)/../TestUtil.hpp readutil_test.cpp
 cgns_test_SOURCES=$(srcdir)/../TestUtil.hpp cgns_test.cpp
 

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index de5d7e1..12b4b29 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -59,6 +59,7 @@ int main(int /* argc */, char** /* argv */)
 void read_file( Interface* moab, const char* input_file )
 {
   InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
 
   ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR(rval);

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index aa11cae..9fa9cd9 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -9,6 +9,9 @@
 #include "moab/Core.hpp"
 #include "MBTagConventions.hpp"
 #include "moab/GeomTopoTool.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+
 using namespace moab;
 
 #define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
@@ -49,13 +52,17 @@ int main(int /* argc */, char** /* argv */)
   int result = 0;
 
   result += RUN_TEST( read_cube_surf_senses_test );  
-
+ 
   return result;
 }
 
 
 void read_file( Interface* moab, const char* input_file )
 {
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+
   ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR( rval );
 }


https://bitbucket.org/fathomteam/moab/commits/2097173fbf69/
Changeset:   2097173fbf69
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:50:45
Summary:     Added all tests back into the read_cgm test files after fixing problems with the CGM instance's persistent geometry.

Affected #:  2 files

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 12b4b29..9e1854c 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -39,18 +39,24 @@ void read_file( Interface* moab, const char* input_file );
 // List of tests in this file
 void read_cube_verts_test();
 void read_cube_curves_test();
+void read_cube_tris_test();
 void read_cube_surfs_test();
 void read_cube_vols_test();
-void read_cube_vertes_pos_test();
+void read_cube_vertex_pos_test();
 void delete_mesh_test();
 
 
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
-
+ 
+  result += RUN_TEST( read_cube_vertex_pos_test );  
   result += RUN_TEST( read_cube_verts_test );  
-
+  result += RUN_TEST( read_cube_curves_test );  
+  result += RUN_TEST( read_cube_tris_test );  
+  result += RUN_TEST( read_cube_surfs_test );  
+  result += RUN_TEST( read_cube_vols_test );  
+ 
   return result;
 }
 

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 9fa9cd9..3b0072e 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -51,6 +51,7 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
+  result += RUN_TEST( read_cube_curve_senses_test );  
   result += RUN_TEST( read_cube_surf_senses_test );  
  
   return result;
@@ -62,7 +63,6 @@ void read_file( Interface* moab, const char* input_file )
   InitCGMA::initialize_cgma();
   GeometryQueryTool::instance()->delete_geometry();
 
-
   ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR( rval );
 }


https://bitbucket.org/fathomteam/moab/commits/1d3c8bc9e78c/
Changeset:   1d3c8bc9e78c
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Updated the ReadCGM test for vertex positions so it doesn't rely on a load order.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 9e1854c..05e11f3 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -50,12 +50,12 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
  
-  result += RUN_TEST( read_cube_vertex_pos_test );  
   result += RUN_TEST( read_cube_verts_test );  
   result += RUN_TEST( read_cube_curves_test );  
   result += RUN_TEST( read_cube_tris_test );  
   result += RUN_TEST( read_cube_surfs_test );  
   result += RUN_TEST( read_cube_vols_test );  
+  result += RUN_TEST( read_cube_vertex_pos_test );  
  
   return result;
 }
@@ -215,45 +215,71 @@ void read_cube_vertex_pos_test()
 
   //Check against known locations of the vertices
 
+  std::vector<double> x_ref;
+  std::vector<double> y_ref;
+  std::vector<double> z_ref;
+
   // Vertex 1
-  CHECK_EQUAL( x[0], 5  );
-  CHECK_EQUAL( y[0], -5 );
-  CHECK_EQUAL( z[0], 5  );
+
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
 
   // Vertex 2
-  CHECK_EQUAL( x[1], 5  );
-  CHECK_EQUAL( y[1], 5  );
-  CHECK_EQUAL( z[1], 5  );
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
 
   // Vertex 3
-  CHECK_EQUAL( x[2], -5 );
-  CHECK_EQUAL( y[2], 5  );
-  CHECK_EQUAL( z[2], 5  );
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
 
   // Vertex 4
-  CHECK_EQUAL( x[3], -5 );
-  CHECK_EQUAL( y[3], -5 );
-  CHECK_EQUAL( z[3], 5  );
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
 
   // Vertex 5
-  CHECK_EQUAL( x[4], 5  );
-  CHECK_EQUAL( y[4], 5  );
-  CHECK_EQUAL( z[4], -5 );
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
 
   // Vertex 6
-  CHECK_EQUAL( x[5], 5  );
-  CHECK_EQUAL( y[5], -5 );
-  CHECK_EQUAL( z[5], -5 );
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
 
   // Vertex 7
-  CHECK_EQUAL( x[6], -5 );
-  CHECK_EQUAL( y[6], -5 );
-  CHECK_EQUAL( z[6], -5 );
-
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
+ 
   // Vertex 8
-  CHECK_EQUAL( x[7], -5 );
-  CHECK_EQUAL( y[7], 5  );
-  CHECK_EQUAL( z[7], -5 );
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
+ 
+
+  std::cout << verts.size() << std::endl;
+  std::cout << x_ref.size() << std::endl;
+  
+  for (unsigned int i=0; i<verts.size(); i++)
+    {
+      for (unsigned int j=0; j<x_ref.size(); j++)
+	{
+	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j])
+            {
+              x_ref.erase( x_ref.begin()+j );
+              y_ref.erase( y_ref.begin()+j );
+              z_ref.erase( z_ref.begin()+j );
+              
+            }
+	}
+    }
+  
+  int leftovers = x_ref.size();
+  CHECK_EQUAL(0, leftovers );
 
 }
 


https://bitbucket.org/fathomteam/moab/commits/42faffb1051e/
Changeset:   42faffb1051e
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Created new file for testing that ReadCGM is loading entities with the correct connectivity.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
new file mode 100644
index 0000000..cbd0849
--- /dev/null
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -0,0 +1,193 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+#else
+static const char input_cube[] = "/io/cube.sat";
+#endif
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// List of tests in this file
+void read_cube_tris_test();
+
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+ 
+  result += RUN_TEST( read_cube_verts_test );  
+  result += RUN_TEST( read_cube_curves_test );  
+  result += RUN_TEST( read_cube_tris_test );  
+  result += RUN_TEST( read_cube_surfs_test );  
+  result += RUN_TEST( read_cube_vols_test );  
+  result += RUN_TEST( read_cube_vertex_pos_test );  
+ 
+  return result;
+}
+
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}
+
+void read_cube_tris_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  int number_of_tris;
+
+  rval = mb->get_number_entities_by_type(0, MBTRI , number_of_tris);
+  std::cout << "Number of Triangles = " << number_of_tris << std::endl;
+  CHECK_ERR(rval);
+
+  CHECK_EQUAL( 12, number_of_tris);  
+
+}
+
+
+void read_cube_vertex_pos_test()
+{
+  
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //First check that the correct number of vertices are present
+  int number_of_verts;
+  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
+  CHECK_ERR( rval );
+
+  CHECK_EQUAL( 8, number_of_verts );
+
+  //Retrieve all vertex handles from the mesh
+  Range verts;
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
+  CHECK_ERR( rval );
+
+  //Get the vertex coordinates
+  double x[verts.size()];
+  double y[verts.size()];
+  double z[verts.size()];
+  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
+  CHECK_ERR( rval );
+
+  //Check against known locations of the vertices
+
+  std::vector<double> x_ref;
+  std::vector<double> y_ref;
+  std::vector<double> z_ref;
+
+  // Vertex 1
+
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 2
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 3
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 4
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 5
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
+
+  // Vertex 6
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
+
+  // Vertex 7
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
+ 
+  // Vertex 8
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
+ 
+
+  std::cout << verts.size() << std::endl;
+  std::cout << x_ref.size() << std::endl;
+  
+  for (unsigned int i=0; i<verts.size(); i++)
+    {
+      for (unsigned int j=0; j<x_ref.size(); j++)
+	{
+	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j])
+            {
+              x_ref.erase( x_ref.begin()+j );
+              y_ref.erase( y_ref.begin()+j );
+              z_ref.erase( z_ref.begin()+j );
+              
+            }
+	}
+    }
+  
+  int leftovers = x_ref.size();
+  CHECK_EQUAL(0, leftovers );
+
+}
+
+ 
+void read_cube_connectivity_test()
+{
+
+   ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //Get all triangles from the mesh
+  std::vector<EntityHandle> tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  CHECK_ERR(rval);
+
+}


https://bitbucket.org/fathomteam/moab/commits/22efd87de07f/
Changeset:   22efd87de07f
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Removed non-existant test calls from read_cgm_connectivity_test.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index cbd0849..e297bfa 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -37,12 +37,7 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
  
-  result += RUN_TEST( read_cube_verts_test );  
-  result += RUN_TEST( read_cube_curves_test );  
-  result += RUN_TEST( read_cube_tris_test );  
-  result += RUN_TEST( read_cube_surfs_test );  
-  result += RUN_TEST( read_cube_vols_test );  
-  result += RUN_TEST( read_cube_vertex_pos_test );  
+
  
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/133937ca1463/
Changeset:   133937ca1463
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Added read_cgm_connectivity_test to the MOAB make check system.

Affected #:  1 file

diff --git a/test/io/Makefile.am b/test/io/Makefile.am
index 4389075..e9a73b3 100644
--- a/test/io/Makefile.am
+++ b/test/io/Makefile.am
@@ -25,7 +25,7 @@ else
 endif
 
 if HAVE_CGM
-  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test
+  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test read_cgm_connectivity_test
 else
   CGM_TEST = 
 endif
@@ -76,6 +76,8 @@ read_cgm_basic_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_basic_test.cpp
 read_cgm_basic_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 read_cgm_senses_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_senses_test.cpp
 read_cgm_senses_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_connectivity_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_connectivity_test.cpp
+read_cgm_connectivity_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 readutil_test_SOURCES = $(srcdir)/../TestUtil.hpp readutil_test.cpp
 cgns_test_SOURCES=$(srcdir)/../TestUtil.hpp cgns_test.cpp
 


https://bitbucket.org/fathomteam/moab/commits/1ed5d04bdc3a/
Changeset:   1ed5d04bdc3a
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Updates to read_cgm_connectivity_test

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index e297bfa..843f2db 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -30,14 +30,18 @@ void read_file( Interface* moab, const char* input_file );
 
 // List of tests in this file
 void read_cube_tris_test();
+void read_cube_connectivity_test();
 
+//Function used to match triangle connectivity and verts 
+void match_tri_connectivity( Range connectivity, 
+                             std::vector<EntityHandle> &reference_verts);
 
 
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
  
-
+  RUN_TEST(read_cube_connectivity_test);
  
   return result;
 }
@@ -180,9 +184,57 @@ void read_cube_connectivity_test()
   Interface* mb = &moab;
   read_file( mb, input_cube );
 
+  //Get all vertex handles from the mesh
+  std::vector<EntityHandle> verts; 
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts);
+  CHECK_ERR(rval);
+  
+  //Duplicate the vertex handles to match the number of tris
+  //they should be connected to upon a correct load
+  std::vector<EntityHandle>  ref_verts=verts;
+  int copy_count = 0;
+  while (copy_count<4)
+    {
+      copy(verts.begin(),verts.end(),back_inserter(ref_verts));
+      copy_count++;
+    }
+  
+  //Make sure everything duplicated without a problem
+  if( ref_verts.size()!=40 ) CHECK_ERR(MB_FAILURE);
+
   //Get all triangles from the mesh
-  std::vector<EntityHandle> tris;
+  Range tris;
   rval = mb->get_entities_by_type( 0, MBTRI, tris);
   CHECK_ERR(rval);
 
+ 
+  //Test connectivity
+  for (Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+    {
+     //Get the connectivity of a triangle
+      Range connect;
+      rval = mb->get_connectivity( &(*i), 1, connect);
+      CHECK_ERR(rval);
+     
+      match_tri_connectivity( connect, ref_verts);
+      std::cout << "ref_verts size = " << ref_verts.size() << std::endl;
+    }
+  
+    
+}
+
+void match_tri_connectivity( Range connectivity, std::vector<EntityHandle> &reference_verts)
+{
+
+  for(Range::const_iterator i=connectivity.begin(); i!=connectivity.end(); i++)
+    {
+
+      for(unsigned int j=0; j<reference_verts.size(); j++)
+	{
+
+	  std::cout << "Triangle Vert Handle = " << *i << std::endl;
+          if( *i == reference_verts[j]) reference_verts.erase(reference_verts.begin()+j);
+             
+	}
+    }
 }


https://bitbucket.org/fathomteam/moab/commits/77669a61d166/
Changeset:   77669a61d166
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:40
Summary:     Added a new test to check that the cube vertices are connected reasonable numbers of triangles.

Updated int main so that it is properly connected to the testing framework.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 843f2db..8d5f103 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -30,18 +30,19 @@ void read_file( Interface* moab, const char* input_file );
 
 // List of tests in this file
 void read_cube_tris_test();
-void read_cube_connectivity_test();
+void cube_verts_connectivity_test();
 
 //Function used to match triangle connectivity and verts 
-void match_tri_connectivity( Range connectivity, 
-                             std::vector<EntityHandle> &reference_verts);
+//void match_tri_connectivity( Range connectivity, 
+//                             std::vector<EntityHandle> &reference_verts);
 
 
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
  
-  RUN_TEST(read_cube_connectivity_test);
+  result += RUN_TEST(cube_verts_connectivity_test);
+  result += RUN_TEST(read_cube_tris_test);
  
   return result;
 }
@@ -76,165 +77,34 @@ void read_cube_tris_test()
 }
 
 
-void read_cube_vertex_pos_test()
+void cube_verts_connectivity_test()
 {
-  
-  ErrorCode rval;
-  //Open the test file
-  Core moab;
-  Interface* mb = &moab;
-  read_file( mb, input_cube );
-
-  //First check that the correct number of vertices are present
-  int number_of_verts;
-  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
-  CHECK_ERR( rval );
-
-  CHECK_EQUAL( 8, number_of_verts );
-
-  //Retrieve all vertex handles from the mesh
-  Range verts;
-  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
-  CHECK_ERR( rval );
-
-  //Get the vertex coordinates
-  double x[verts.size()];
-  double y[verts.size()];
-  double z[verts.size()];
-  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
-  CHECK_ERR( rval );
-
-  //Check against known locations of the vertices
-
-  std::vector<double> x_ref;
-  std::vector<double> y_ref;
-  std::vector<double> z_ref;
-
-  // Vertex 1
-
-  x_ref.push_back( 5 );
-  y_ref.push_back( -5 );
-  z_ref.push_back( 5 );
-
-  // Vertex 2
-  x_ref.push_back( 5 );
-  y_ref.push_back( 5 );
-  z_ref.push_back( 5 );
-
-  // Vertex 3
-  x_ref.push_back( -5 );
-  y_ref.push_back( 5 );
-  z_ref.push_back( 5 );
-
-  // Vertex 4
-  x_ref.push_back( -5 );
-  y_ref.push_back( -5 );
-  z_ref.push_back( 5 );
-
-  // Vertex 5
-  x_ref.push_back( 5 );
-  y_ref.push_back( 5 );
-  z_ref.push_back( -5 );
-
-  // Vertex 6
-  x_ref.push_back( 5 );
-  y_ref.push_back( -5 );
-  z_ref.push_back( -5 );
-
-  // Vertex 7
-  x_ref.push_back( -5 );
-  y_ref.push_back( -5 );
-  z_ref.push_back( -5 );
- 
-  // Vertex 8
-  x_ref.push_back( -5 );
-  y_ref.push_back( 5 );
-  z_ref.push_back( -5 );
- 
-
-  std::cout << verts.size() << std::endl;
-  std::cout << x_ref.size() << std::endl;
-  
-  for (unsigned int i=0; i<verts.size(); i++)
-    {
-      for (unsigned int j=0; j<x_ref.size(); j++)
-	{
-	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j])
-            {
-              x_ref.erase( x_ref.begin()+j );
-              y_ref.erase( y_ref.begin()+j );
-              z_ref.erase( z_ref.begin()+j );
-              
-            }
-	}
-    }
-  
-  int leftovers = x_ref.size();
-  CHECK_EQUAL(0, leftovers );
 
-}
-
- 
-void read_cube_connectivity_test()
-{
-
-   ErrorCode rval;
+  ErrorCode rval;
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cube);
 
   //Get all vertex handles from the mesh
-  std::vector<EntityHandle> verts; 
+  Range verts;
   rval = mb->get_entities_by_type( 0, MBVERTEX, verts);
   CHECK_ERR(rval);
-  
-  //Duplicate the vertex handles to match the number of tris
-  //they should be connected to upon a correct load
-  std::vector<EntityHandle>  ref_verts=verts;
-  int copy_count = 0;
-  while (copy_count<4)
-    {
-      copy(verts.begin(),verts.end(),back_inserter(ref_verts));
-      copy_count++;
-    }
-  
-  //Make sure everything duplicated without a problem
-  if( ref_verts.size()!=40 ) CHECK_ERR(MB_FAILURE);
 
-  //Get all triangles from the mesh
-  Range tris;
-  rval = mb->get_entities_by_type( 0, MBTRI, tris);
-  CHECK_ERR(rval);
+  //Check that each vertex connects to less than 4 triangles and no more than 6
 
- 
-  //Test connectivity
-  for (Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+  for(Range::const_iterator i = verts.begin(); i!=verts.end(); i++)
     {
-     //Get the connectivity of a triangle
-      Range connect;
-      rval = mb->get_connectivity( &(*i), 1, connect);
+      std::vector<EntityHandle> adj_tris;
+      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris );
       CHECK_ERR(rval);
-     
-      match_tri_connectivity( connect, ref_verts);
-      std::cout << "ref_verts size = " << ref_verts.size() << std::endl;
-    }
-  
-    
-}
-
-void match_tri_connectivity( Range connectivity, std::vector<EntityHandle> &reference_verts)
-{
 
-  for(Range::const_iterator i=connectivity.begin(); i!=connectivity.end(); i++)
-    {
+      int adj_size = adj_tris.size();
 
-      for(unsigned int j=0; j<reference_verts.size(); j++)
-	{
+      CHECK( adj_size >= 4 && adj_size <= 6);
 
-	  std::cout << "Triangle Vert Handle = " << *i << std::endl;
-          if( *i == reference_verts[j]) reference_verts.erase(reference_verts.begin()+j);
-             
-	}
     }
+    
+
 }
+


https://bitbucket.org/fathomteam/moab/commits/747b1a402153/
Changeset:   747b1a402153
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Corrected formatting in read_cgm_senses_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 3b0072e..9b3f038 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -32,9 +32,9 @@ void read_file( Interface* moab, const char* input_file );
 // Functions containing known sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
 void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+
 // Functions used to compare sense information found in 
 // the model to reference information
-
 void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
                              std::vector<int> known_wrt_ids, std::vector<int> known_senses );
 


https://bitbucket.org/fathomteam/moab/commits/3af7974bc063/
Changeset:   3af7974bc063
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added a test to ensure that each triangle in the loaded file is adjacent to 3 other triangles.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 8d5f103..686ebaa 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -10,7 +10,7 @@
 #include "MBTagConventions.hpp"
 #include "InitCGMA.hpp"
 #include "GeometryQueryTool.hpp"
-
+#include "moab/MeshTopoUtil.hpp"
 using namespace moab;
 
 #define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
@@ -31,6 +31,7 @@ void read_file( Interface* moab, const char* input_file );
 // List of tests in this file
 void read_cube_tris_test();
 void cube_verts_connectivity_test();
+void cube_tris_connectivity_test();
 
 //Function used to match triangle connectivity and verts 
 //void match_tri_connectivity( Range connectivity, 
@@ -43,6 +44,7 @@ int main(int /* argc */, char** /* argv */)
  
   result += RUN_TEST(cube_verts_connectivity_test);
   result += RUN_TEST(read_cube_tris_test);
+  result += RUN_TEST(cube_tris_connectivity_test);
  
   return result;
 }
@@ -100,11 +102,34 @@ void cube_verts_connectivity_test()
       CHECK_ERR(rval);
 
       int adj_size = adj_tris.size();
-
       CHECK( adj_size >= 4 && adj_size <= 6);
-
     }
     
+}
+
+void cube_tris_connectivity_test()
+{
+    ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube);
+
+  //Get triangles from the mesh
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  CHECK_ERR(rval);
+
+
+  for(Range::const_iterator i = tris.begin()+1; i!=tris.end(); i++)
+    {
+      Range adj_tris;
+      moab::MeshTopoUtil mu(mb);
+      rval = mu.get_bridge_adjacencies( *i, 1, 2, adj_tris);
+      CHECK_ERR(rval);
+      int number_of_adj_tris=adj_tris.size();      
+      CHECK_EQUAL( 3, number_of_adj_tris);
+    }
 
 }
 


https://bitbucket.org/fathomteam/moab/commits/cadd7b20c48a/
Changeset:   cadd7b20c48a
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Removed read_cube_tris_test from the connectivity test file.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 686ebaa..651f635 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -29,7 +29,6 @@ static const char input_cube[] = "/io/cube.sat";
 void read_file( Interface* moab, const char* input_file );
 
 // List of tests in this file
-void read_cube_tris_test();
 void cube_verts_connectivity_test();
 void cube_tris_connectivity_test();
 
@@ -43,7 +42,6 @@ int main(int /* argc */, char** /* argv */)
   int result = 0;
  
   result += RUN_TEST(cube_verts_connectivity_test);
-  result += RUN_TEST(read_cube_tris_test);
   result += RUN_TEST(cube_tris_connectivity_test);
  
   return result;
@@ -60,25 +58,6 @@ void read_file( Interface* moab, const char* input_file )
   CHECK_ERR(rval);
 }
 
-void read_cube_tris_test()
-{
-  ErrorCode rval;
-  //Open the test file
-  Core moab;
-  Interface* mb = &moab;
-  read_file( mb, input_cube );
-   
-  int number_of_tris;
-
-  rval = mb->get_number_entities_by_type(0, MBTRI , number_of_tris);
-  std::cout << "Number of Triangles = " << number_of_tris << std::endl;
-  CHECK_ERR(rval);
-
-  CHECK_EQUAL( 12, number_of_tris);  
-
-}
-
-
 void cube_verts_connectivity_test()
 {
 


https://bitbucket.org/fathomteam/moab/commits/ac2418c1f79e/
Changeset:   ac2418c1f79e
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Removed deprecated and commented test prototype.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 651f635..f82d8cd 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -32,10 +32,6 @@ void read_file( Interface* moab, const char* input_file );
 void cube_verts_connectivity_test();
 void cube_tris_connectivity_test();
 
-//Function used to match triangle connectivity and verts 
-//void match_tri_connectivity( Range connectivity, 
-//                             std::vector<EntityHandle> &reference_verts);
-
 
 int main(int /* argc */, char** /* argv */)
 {


https://bitbucket.org/fathomteam/moab/commits/c5a98372252c/
Changeset:   c5a98372252c
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added a test for triangle-edge coincidence in the case of a cube read by ReadCGM

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index f82d8cd..903dfcb 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -31,7 +31,10 @@ void read_file( Interface* moab, const char* input_file );
 // List of tests in this file
 void cube_verts_connectivity_test();
 void cube_tris_connectivity_test();
+void cube_tri_curve_coincidence_test();
 
+//Other functions
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves);
 
 int main(int /* argc */, char** /* argv */)
 {
@@ -39,6 +42,7 @@ int main(int /* argc */, char** /* argv */)
  
   result += RUN_TEST(cube_verts_connectivity_test);
   result += RUN_TEST(cube_tris_connectivity_test);
+  result += RUN_TEST(cube_tri_curve_coincidence_test);
  
   return result;
 }
@@ -84,7 +88,7 @@ void cube_verts_connectivity_test()
 
 void cube_tris_connectivity_test()
 {
-    ErrorCode rval;
+  ErrorCode rval;
   //Open the test file
   Core moab;
   Interface* mb = &moab;
@@ -108,3 +112,58 @@ void cube_tris_connectivity_test()
 
 }
 
+void cube_tri_curve_coincidence_test()
+{
+
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube);
+
+  //Get curves from the mesh
+  Range curves;
+  rval = mb->get_entities_by_type( 0, MBEDGE, curves);
+  CHECK_ERR(rval);
+
+  //Get triangles from the mesh
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+    {
+      //Get the any curve edges that are a part of the triangle
+      Range tri_edges;
+      rval = mb->get_adjacencies( &(*i), 1, 1, false, tri_edges);
+      CHECK_ERR(rval);
+
+      int num_of_tri_edges = tri_edges.size();
+      CHECK_EQUAL(2, num_of_tri_edges);
+      rval = match_tri_edges_w_curve( mb, tri_edges, curves);
+      CHECK_ERR(rval);
+  
+    }
+
+}
+
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves)
+{
+
+  ErrorCode rval;
+  int match_counter;
+  std::cout << "Size of curves = " << curves.size() << std::endl;
+  for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)
+    {
+      for(Range::const_iterator j=curves.begin(); j!=curves.end(); j++)
+	{
+	  std::cout << "Tri edge ID = " <<  *i << std::endl;
+	  std::cout << "Curve edge ID = " << *j << std::endl;
+          if( *i  == *j  ) match_counter++;
+	}
+    }
+
+  int num_of_tri_edges = tri_edges.size();
+  CHECK_EQUAL( num_of_tri_edges, match_counter );
+  return MB_SUCCESS;
+} 


https://bitbucket.org/fathomteam/moab/commits/3e9891fb06b8/
Changeset:   3e9891fb06b8
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added a test to read_cgm_connectivity_test to ensure that each triangle has three different vertices.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 903dfcb..4d4bebf 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -32,6 +32,8 @@ void read_file( Interface* moab, const char* input_file );
 void cube_verts_connectivity_test();
 void cube_tris_connectivity_test();
 void cube_tri_curve_coincidence_test();
+void cube_edge_adjacencies_test();
+void cube_tri_vertex_test();
 
 //Other functions
 ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves);
@@ -43,6 +45,8 @@ int main(int /* argc */, char** /* argv */)
   result += RUN_TEST(cube_verts_connectivity_test);
   result += RUN_TEST(cube_tris_connectivity_test);
   result += RUN_TEST(cube_tri_curve_coincidence_test);
+  result += RUN_TEST(cube_tri_curve_coincidence_test);
+  result += RUN_TEST(cube_tri_vertex_test);
  
   return result;
 }
@@ -167,3 +171,59 @@ ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curve
   CHECK_EQUAL( num_of_tri_edges, match_counter );
   return MB_SUCCESS;
 } 
+
+void cube_edge_adjacencies_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube);
+
+  //Get the curves 
+  Range curves;
+  rval = mb->get_entities_by_type(0, MBEDGE, curves);
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=curves.begin(); i!=curves.end(); i++)
+    {
+      //Get triangle adjacent to each edge
+      Range adj_tris;
+      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris);
+      CHECK_ERR(rval);
+      
+      int num_adj_tris = adj_tris.size();
+      //Ensure that an edge isn't adjacent to more than two triangles
+      CHECK( num_adj_tris <= 2);
+    }
+
+}
+
+void cube_tri_vertex_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube);
+ 
+  //Get all triangles
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+    {
+      //Get all triangle vertices
+      Range verts;
+      rval = mb->get_connectivity( &(*i), 1, verts);
+      CHECK_ERR(rval);
+
+      int number_of_verts = verts.size();
+      CHECK( 3 == number_of_verts);
+      CHECK(verts[0]!=verts[1]);
+      CHECK(verts[1]!=verts[2]);      
+      CHECK(verts[2]!=verts[0]);
+    } 
+
+}


https://bitbucket.org/fathomteam/moab/commits/8ba58c12e905/
Changeset:   8ba58c12e905
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added a check that all entities in cube_tris_connectivity_test are triangles and removed deprecated print outs.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 4d4bebf..65e8237 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -108,10 +108,18 @@ void cube_tris_connectivity_test()
     {
       Range adj_tris;
       moab::MeshTopoUtil mu(mb);
+      //Use Triangle edges to get all adjacent triangles
       rval = mu.get_bridge_adjacencies( *i, 1, 2, adj_tris);
       CHECK_ERR(rval);
       int number_of_adj_tris=adj_tris.size();      
       CHECK_EQUAL( 3, number_of_adj_tris);
+      
+      //Check that the entities we found from bridge_adjacencies
+      //are triangles
+      Range adj_tri_test = adj_tris.subset_by_type(MBTRI);
+      int number_tris_in_adj_tris = adj_tri_test.size();
+      CHECK_EQUAL( number_of_adj_tris, number_tris_in_adj_tris);
+    
     }
 
 }
@@ -155,14 +163,11 @@ ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curve
 {
 
   ErrorCode rval;
-  int match_counter;
-  std::cout << "Size of curves = " << curves.size() << std::endl;
+  int match_counter=0;
   for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)
     {
       for(Range::const_iterator j=curves.begin(); j!=curves.end(); j++)
 	{
-	  std::cout << "Tri edge ID = " <<  *i << std::endl;
-	  std::cout << "Curve edge ID = " << *j << std::endl;
           if( *i  == *j  ) match_counter++;
 	}
     }


https://bitbucket.org/fathomteam/moab/commits/21be0f515a7e/
Changeset:   21be0f515a7e
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Formatting corrections for read_cgm_connectivity_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 65e8237..7137666 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -36,7 +36,7 @@ void cube_edge_adjacencies_test();
 void cube_tri_vertex_test();
 
 //Other functions
-ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves);
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves );
 
 int main(int /* argc */, char** /* argv */)
 {
@@ -69,11 +69,11 @@ void cube_verts_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube);
+  read_file( mb, input_cube );
 
   //Get all vertex handles from the mesh
   Range verts;
-  rval = mb->get_entities_by_type( 0, MBVERTEX, verts);
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
   CHECK_ERR(rval);
 
   //Check that each vertex connects to less than 4 triangles and no more than 6
@@ -85,7 +85,7 @@ void cube_verts_connectivity_test()
       CHECK_ERR(rval);
 
       int adj_size = adj_tris.size();
-      CHECK( adj_size >= 4 && adj_size <= 6);
+      CHECK( adj_size >= 4 && adj_size <= 6 );
     }
     
 }
@@ -96,11 +96,11 @@ void cube_tris_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube);
+  read_file( mb, input_cube );
 
   //Get triangles from the mesh
   Range tris;
-  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
   CHECK_ERR(rval);
 
 
@@ -109,16 +109,16 @@ void cube_tris_connectivity_test()
       Range adj_tris;
       moab::MeshTopoUtil mu(mb);
       //Use Triangle edges to get all adjacent triangles
-      rval = mu.get_bridge_adjacencies( *i, 1, 2, adj_tris);
+      rval = mu.get_bridge_adjacencies( *i, 1, 2, adj_tris );
       CHECK_ERR(rval);
       int number_of_adj_tris=adj_tris.size();      
-      CHECK_EQUAL( 3, number_of_adj_tris);
+      CHECK_EQUAL( 3, number_of_adj_tris );
       
       //Check that the entities we found from bridge_adjacencies
       //are triangles
-      Range adj_tri_test = adj_tris.subset_by_type(MBTRI);
+      Range adj_tri_test = adj_tris.subset_by_type( MBTRI );
       int number_tris_in_adj_tris = adj_tri_test.size();
-      CHECK_EQUAL( number_of_adj_tris, number_tris_in_adj_tris);
+      CHECK_EQUAL( number_of_adj_tris, number_tris_in_adj_tris );
     
     }
 
@@ -131,35 +131,35 @@ void cube_tri_curve_coincidence_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube);
+  read_file( mb, input_cube );
 
   //Get curves from the mesh
   Range curves;
-  rval = mb->get_entities_by_type( 0, MBEDGE, curves);
+  rval = mb->get_entities_by_type( 0, MBEDGE, curves );
   CHECK_ERR(rval);
 
   //Get triangles from the mesh
   Range tris;
-  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
   CHECK_ERR(rval);
 
   for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
     {
       //Get the any curve edges that are a part of the triangle
       Range tri_edges;
-      rval = mb->get_adjacencies( &(*i), 1, 1, false, tri_edges);
+      rval = mb->get_adjacencies( &(*i), 1, 1, false, tri_edges );
       CHECK_ERR(rval);
 
       int num_of_tri_edges = tri_edges.size();
-      CHECK_EQUAL(2, num_of_tri_edges);
-      rval = match_tri_edges_w_curve( mb, tri_edges, curves);
+      CHECK_EQUAL( 2, num_of_tri_edges );
+      rval = match_tri_edges_w_curve( mb, tri_edges, curves );
       CHECK_ERR(rval);
   
     }
 
 }
 
-ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves)
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
 {
 
   ErrorCode rval;
@@ -183,23 +183,23 @@ void cube_edge_adjacencies_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube);
+  read_file( mb, input_cube );
 
   //Get the curves 
   Range curves;
-  rval = mb->get_entities_by_type(0, MBEDGE, curves);
+  rval = mb->get_entities_by_type( 0, MBEDGE, curves );
   CHECK_ERR(rval);
 
   for(Range::const_iterator i=curves.begin(); i!=curves.end(); i++)
     {
       //Get triangle adjacent to each edge
       Range adj_tris;
-      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris);
+      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris );
       CHECK_ERR(rval);
       
       int num_adj_tris = adj_tris.size();
       //Ensure that an edge isn't adjacent to more than two triangles
-      CHECK( num_adj_tris <= 2);
+      CHECK( num_adj_tris <= 2 );
     }
 
 }
@@ -210,25 +210,25 @@ void cube_tri_vertex_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube);
+  read_file( mb, input_cube );
  
   //Get all triangles
   Range tris;
-  rval = mb->get_entities_by_type( 0, MBTRI, tris);
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
   CHECK_ERR(rval);
 
   for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
     {
       //Get all triangle vertices
       Range verts;
-      rval = mb->get_connectivity( &(*i), 1, verts);
+      rval = mb->get_connectivity( &(*i), 1, verts );
       CHECK_ERR(rval);
 
       int number_of_verts = verts.size();
-      CHECK( 3 == number_of_verts);
-      CHECK(verts[0]!=verts[1]);
-      CHECK(verts[1]!=verts[2]);      
-      CHECK(verts[2]!=verts[0]);
+      CHECK( 3 == number_of_verts );
+      CHECK( verts[0]!=verts[1] );
+      CHECK( verts[1]!=verts[2] );      
+      CHECK( verts[2]!=verts[0] );
     } 
 
 }


https://bitbucket.org/fathomteam/moab/commits/abee5754a035/
Changeset:   abee5754a035
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Formatting corrections for read_cgm_load_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_load_test.cpp b/test/io/read_cgm_load_test.cpp
index 9704ee7..6791f50 100644
--- a/test/io/read_cgm_load_test.cpp
+++ b/test/io/read_cgm_load_test.cpp
@@ -33,10 +33,10 @@ void read_multiple_test()
 {
   Core mb;
 
-  ErrorCode rval = mb.load_file(input_file);
+  ErrorCode rval = mb.load_file( input_file );
   CHECK_ERR(rval);
   // second load
-  rval = mb.load_file(input_file);
+  rval = mb.load_file( input_file );
   CHECK_ERR(rval);
 
 }
@@ -44,7 +44,7 @@ void read_multiple_test()
 int main(int /* argc */, char** /* argv */)
 {
   
-  int result = RUN_TEST( read_multiple_test ) ;
+  int result = RUN_TEST( read_multiple_test );
 
   return result;
 }


https://bitbucket.org/fathomteam/moab/commits/288dfea854df/
Changeset:   288dfea854df
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Formatting corrections to read_cgm_basic_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 05e11f3..aca6c7a 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -50,12 +50,12 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
  
-  result += RUN_TEST( read_cube_verts_test );  
-  result += RUN_TEST( read_cube_curves_test );  
-  result += RUN_TEST( read_cube_tris_test );  
-  result += RUN_TEST( read_cube_surfs_test );  
-  result += RUN_TEST( read_cube_vols_test );  
-  result += RUN_TEST( read_cube_vertex_pos_test );  
+  result += RUN_TEST(read_cube_verts_test);  
+  result += RUN_TEST(read_cube_curves_test);  
+  result += RUN_TEST(read_cube_tris_test);  
+  result += RUN_TEST(read_cube_surfs_test);  
+  result += RUN_TEST(read_cube_vols_test);  
+  result += RUN_TEST(read_cube_vertex_pos_test);  
  
   return result;
 }
@@ -80,10 +80,10 @@ void read_cube_verts_test()
   read_file( mb, input_cube );
    
   int number_of_vertices;
-  rval = mb->get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
+  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_vertices );
   CHECK_ERR(rval);
  
-  CHECK_EQUAL( 8, number_of_vertices);
+  CHECK_EQUAL( 8, number_of_vertices );
 }
 
 
@@ -97,11 +97,11 @@ void read_cube_tris_test()
    
   int number_of_tris;
 
-  rval = mb->get_number_entities_by_type(0, MBTRI , number_of_tris);
+  rval = mb->get_number_entities_by_type( 0, MBTRI , number_of_tris );
   std::cout << "Number of Triangles = " << number_of_tris << std::endl;
   CHECK_ERR(rval);
 
-  CHECK_EQUAL( 12, number_of_tris);  
+  CHECK_EQUAL( 12, number_of_tris );  
 
 }
 
@@ -127,7 +127,7 @@ void read_cube_curves_test()
 	  					    val, 1, number_of_curves );
   CHECK_ERR(rval);
 
-  CHECK_EQUAL( 12, number_of_curves);  
+  CHECK_EQUAL( 12, number_of_curves );  
 
 } 
 
@@ -151,7 +151,7 @@ void read_cube_surfs_test()
   int number_of_surfs;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_surfs );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   
 
   CHECK_EQUAL( 6, number_of_surfs );  
@@ -170,7 +170,7 @@ void read_cube_vols_test()
   Tag geom_tag;
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
                              geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   
   Range curves;
   int dim = 3;
@@ -178,7 +178,7 @@ void read_cube_vols_test()
   int number_of_vols;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_vols );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   
 
   CHECK_EQUAL( 1, number_of_vols );
@@ -197,7 +197,7 @@ void read_cube_vertex_pos_test()
   //First check that the correct number of vertices are present
   int number_of_verts;
   rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
 
   CHECK_EQUAL( 8, number_of_verts );
 
@@ -211,7 +211,7 @@ void read_cube_vertex_pos_test()
   double y[verts.size()];
   double z[verts.size()];
   rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
 
   //Check against known locations of the vertices
 
@@ -268,7 +268,7 @@ void read_cube_vertex_pos_test()
     {
       for (unsigned int j=0; j<x_ref.size(); j++)
 	{
-	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j])
+	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j] )
             {
               x_ref.erase( x_ref.begin()+j );
               y_ref.erase( y_ref.begin()+j );
@@ -279,7 +279,7 @@ void read_cube_vertex_pos_test()
     }
   
   int leftovers = x_ref.size();
-  CHECK_EQUAL(0, leftovers );
+  CHECK_EQUAL( 0, leftovers );
 
 }
 
@@ -304,7 +304,7 @@ void delete_mesh_test()
 	void *val[] = {&dim};
 	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, geom_sets[dim] );
-        CHECK_ERR( rval ); 
+        CHECK_ERR(rval); 
 
         if( geom_sets[dim].size() == 0 ) std::cout << "Warning: No geom sets to begin with" << std::endl;
 
@@ -318,11 +318,11 @@ void delete_mesh_test()
 	void *val_after[] = {&dim};
 	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val_after, 1, geom_sets_after[dim] );
-        CHECK_ERR( rval ); 
+        CHECK_ERR(rval); 
 
         if( 0 != geom_sets_after[dim].size() ) rval = MB_FAILURE;
 
-        CHECK_ERR( rval );
+        CHECK_ERR(rval);
  }
 
 }


https://bitbucket.org/fathomteam/moab/commits/e03e08667d1f/
Changeset:   e03e08667d1f
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Formatting corrections to read_cgm_senses_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 9b3f038..904477a 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -51,8 +51,8 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST( read_cube_curve_senses_test );  
-  result += RUN_TEST( read_cube_surf_senses_test );  
+  result += RUN_TEST(read_cube_curve_senses_test);  
+  result += RUN_TEST(read_cube_surf_senses_test);  
  
   return result;
 }
@@ -64,7 +64,7 @@ void read_file( Interface* moab, const char* input_file )
   GeometryQueryTool::instance()->delete_geometry();
 
   ErrorCode rval = moab->load_file( input_file );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
 }
 
 void read_cube_curve_senses_test()
@@ -80,7 +80,7 @@ void read_cube_curve_senses_test()
 
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
 				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   
   // Check that the proper number of curves exist
 
@@ -89,14 +89,14 @@ void read_cube_curve_senses_test()
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   CHECK_EQUAL( 12 , number_of_curves );
   
   // Get curve handles
   Range curves;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, curves );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
 
   // Establish GeomTopoTool instance needed to get curve data 
   moab::GeomTopoTool gt( mb, false );  
@@ -112,7 +112,7 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    surfs.clear();
    senses.clear();
    //Get sense info for the current curve
-   gt.get_senses( curves[i], surfs, senses);
+   gt.get_senses( curves[i], surfs, senses );
    CHECK_ERR(rval);
 
    //Clear reference data from previous curve
@@ -138,7 +138,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
                       
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
-    CHECK_ERR( rval );                        
+    CHECK_ERR(rval);                        
     return id;
  }
 
@@ -148,20 +148,20 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
   
   //Get ID's of the wrt entities
   std::vector<int> wrt_ent_ids;
-  for( unsigned int i=0 ; i<wrt_ents.size() ; i++ )
+  for(unsigned int i=0 ; i<wrt_ents.size() ; i++)
   {
-      wrt_ent_ids.push_back( geom_id_by_handle( moab, wrt_ents[i] ));
+      wrt_ent_ids.push_back( geom_id_by_handle( moab, wrt_ents[i] ) );
   }
 
-  for ( unsigned int i=0; i< wrt_ent_ids.size() ; i++ )
+  for(unsigned int i=0; i< wrt_ent_ids.size() ; i++)
   {
-     for( unsigned int j=0; j< known_wrt_ids.size(); j++ )
+     for(unsigned int j=0; j< known_wrt_ids.size(); j++)
      {
        if( wrt_ent_ids[i] == known_wrt_ids [j] )
          {
           // Make sure the senses of the matching wrt entities
           // are correct
-          CHECK_EQUAL( senses[i],known_senses[j] );
+          CHECK_EQUAL( senses[i], known_senses[j] );
           //Once a wrt entity is matched with a known entity,
           // remove it from the list
           known_wrt_ids.erase( known_wrt_ids.begin()+j );
@@ -176,7 +176,8 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
 
 }
 
-void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out ){
+void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+{
 
   int curve_id = geom_id_by_handle( moab, curve );
 
@@ -260,7 +261,7 @@ void read_cube_surf_senses_test()
   Tag geom_tag;
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
                              geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   
   // Check that the proper number of curves exist
   int dim = 2;
@@ -268,14 +269,14 @@ void read_cube_surf_senses_test()
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
   CHECK_EQUAL( 6, number_of_curves );
   
   // Get curve handles
   Range surfs;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, surfs );
-  CHECK_ERR( rval );
+  CHECK_ERR(rval);
 
   // Establish GeomTopoTool instance needed to get curve data 
   moab::GeomTopoTool gt( mb, false );  
@@ -284,14 +285,14 @@ void read_cube_surf_senses_test()
   std::vector<int> known_vol_ids;
   std::vector<int> known_senses;
 
-for( unsigned int i = 0; i < surfs.size() ; i++ )
+for(unsigned int i = 0; i < surfs.size(); i++)
   {
    //Clean data from previous surface
    vols.clear();
    senses.clear();
    // Get sense information for the current
    // surface from the mesh
-   gt.get_senses( surfs[i], vols, senses);
+   gt.get_senses( surfs[i], vols, senses );
    CHECK_ERR(rval);
 
    //Load known curve-sense data
@@ -300,7 +301,7 @@ for( unsigned int i = 0; i < surfs.size() ; i++ )
    load_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
    // Check sense information from the loaded mesh against 
    // reference sense information
-   check_sense_data( mb, vols, senses, known_vol_ids, known_senses);
+   check_sense_data( mb, vols, senses, known_vol_ids, known_senses );
 
   }
 


https://bitbucket.org/fathomteam/moab/commits/5d58573ff3be/
Changeset:   5d58573ff3be
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added comments to read_cgm_connectivity_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 7137666..afffbe7 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -77,7 +77,6 @@ void cube_verts_connectivity_test()
   CHECK_ERR(rval);
 
   //Check that each vertex connects to less than 4 triangles and no more than 6
-
   for(Range::const_iterator i = verts.begin(); i!=verts.end(); i++)
     {
       std::vector<EntityHandle> adj_tris;
@@ -149,29 +148,31 @@ void cube_tri_curve_coincidence_test()
       Range tri_edges;
       rval = mb->get_adjacencies( &(*i), 1, 1, false, tri_edges );
       CHECK_ERR(rval);
-
+      //Check that we've retrieved two edges from get_adjacencies
+      //For a this file (cube), each triangle should have two curve
+      //edges
       int num_of_tri_edges = tri_edges.size();
       CHECK_EQUAL( 2, num_of_tri_edges );
       rval = match_tri_edges_w_curve( mb, tri_edges, curves );
       CHECK_ERR(rval);
-  
-    }
-
+      }
 }
 
 ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
 {
-
   ErrorCode rval;
   int match_counter=0;
   for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)
     {
       for(Range::const_iterator j=curves.begin(); j!=curves.end(); j++)
 	{
+          // If the edge handle matches a curve handle, increment the number
+          // matches
           if( *i  == *j  ) match_counter++;
 	}
     }
-
+  //Make sure that each edge returned from triangle edges
+  //has been matched to a curve
   int num_of_tri_edges = tri_edges.size();
   CHECK_EQUAL( num_of_tri_edges, match_counter );
   return MB_SUCCESS;
@@ -198,7 +199,7 @@ void cube_edge_adjacencies_test()
       CHECK_ERR(rval);
       
       int num_adj_tris = adj_tris.size();
-      //Ensure that an edge isn't adjacent to more than two triangles
+      //Ensure that no edge is adjacent to more than two triangles
       CHECK( num_adj_tris <= 2 );
     }
 
@@ -223,7 +224,8 @@ void cube_tri_vertex_test()
       Range verts;
       rval = mb->get_connectivity( &(*i), 1, verts );
       CHECK_ERR(rval);
-
+      //Make sure that each vertex making up
+      //the triangle is different
       int number_of_verts = verts.size();
       CHECK( 3 == number_of_verts );
       CHECK( verts[0]!=verts[1] );


https://bitbucket.org/fathomteam/moab/commits/7401d90b969c/
Changeset:   7401d90b969c
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Removed white space in read_cgm_connectivity_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index afffbe7..f0e67c24 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -232,5 +232,4 @@ void cube_tri_vertex_test()
       CHECK( verts[1]!=verts[2] );      
       CHECK( verts[2]!=verts[0] );
     } 
-
 }


https://bitbucket.org/fathomteam/moab/commits/6384fd372afe/
Changeset:   6384fd372afe
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Cleanup of read_cgm_basic_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index aca6c7a..3a68d04 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -43,7 +43,7 @@ void read_cube_tris_test();
 void read_cube_surfs_test();
 void read_cube_vols_test();
 void read_cube_vertex_pos_test();
-void delete_mesh_test();
+//void delete_mesh_test();
 
 
 int main(int /* argc */, char** /* argv */)
@@ -82,7 +82,7 @@ void read_cube_verts_test()
   int number_of_vertices;
   rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_vertices );
   CHECK_ERR(rval);
- 
+  //For a cube there should be exactly 8 vertices 
   CHECK_EQUAL( 8, number_of_vertices );
 }
 
@@ -100,9 +100,8 @@ void read_cube_tris_test()
   rval = mb->get_number_entities_by_type( 0, MBTRI , number_of_tris );
   std::cout << "Number of Triangles = " << number_of_tris << std::endl;
   CHECK_ERR(rval);
-
+  //For a cube, there should be exactly 2 triangles per face
   CHECK_EQUAL( 12, number_of_tris );  
-
 }
 
 void read_cube_curves_test()
@@ -112,21 +111,19 @@ void read_cube_curves_test()
   Core moab;
   Interface* mb = &moab;
   read_file( mb, input_cube );
-   
+  //Get the geometry tag handle from the mesh   
   Tag geom_tag;
-
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
 				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
-  
-  Range curves;
+  //Get the curves from the mesh
   int dim = 1;
   void *val[] = {&dim};
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_curves );
   CHECK_ERR(rval);
-
+  //For a cube, there should be exactly 12 curves loaded from the file
   CHECK_EQUAL( 12, number_of_curves );  
 
 } 
@@ -145,15 +142,14 @@ void read_cube_surfs_test()
                              geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
   
-  Range curves;
+  //Get the number of surface from the mesh geometry data
   int dim = 2;
   void *val[] = {&dim};
   int number_of_surfs;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_surfs );
   CHECK_ERR(rval);
-  
-
+  //For a cube, there should be exactly 6 surfaces  
   CHECK_EQUAL( 6, number_of_surfs );  
 
 }
@@ -172,17 +168,14 @@ void read_cube_vols_test()
                              geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
   
-  Range curves;
+  //Get the number of volumes from the mesh geometry data
   int dim = 3;
   void *val[] = {&dim};
   int number_of_vols;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_vols );
   CHECK_ERR(rval);
-  
-
   CHECK_EQUAL( 1, number_of_vols );
-
 }
 
 void read_cube_vertex_pos_test()
@@ -220,7 +213,6 @@ void read_cube_vertex_pos_test()
   std::vector<double> z_ref;
 
   // Vertex 1
-
   x_ref.push_back( 5 );
   y_ref.push_back( -5 );
   z_ref.push_back( 5 );
@@ -260,29 +252,34 @@ void read_cube_vertex_pos_test()
   y_ref.push_back( 5 );
   z_ref.push_back( -5 );
  
-
   std::cout << verts.size() << std::endl;
   std::cout << x_ref.size() << std::endl;
   
-  for (unsigned int i=0; i<verts.size(); i++)
+  for(unsigned int i=0; i<verts.size(); i++)
     {
-      for (unsigned int j=0; j<x_ref.size(); j++)
+      for(unsigned int j=0; j<x_ref.size(); j++)
 	{
 	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j] )
             {
               x_ref.erase( x_ref.begin()+j );
               y_ref.erase( y_ref.begin()+j );
               z_ref.erase( z_ref.begin()+j );
-              
             }
 	}
     }
   
+  //After looping through each vertex loaded from the mesh
+  //there should be no entities left in the reference vector
   int leftovers = x_ref.size();
   CHECK_EQUAL( 0, leftovers );
 
 }
 
+//Superfluous test for ReadCGM, but perhaps better 
+//than the test in place for moab::delete_geometry()
+
+
+/*
 void delete_mesh_test()
 {
  Core moab;
@@ -327,3 +324,4 @@ void delete_mesh_test()
 
 }
  
+*/


https://bitbucket.org/fathomteam/moab/commits/9ace8129a418/
Changeset:   9ace8129a418
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Cleanup of read_cgm_senses_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 904477a..4f0896d 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -77,22 +77,20 @@ void read_cube_curve_senses_test()
   
   //Get all curve handles
   Tag geom_tag;
-
   rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
-				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+			MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
   
   // Check that the proper number of curves exist
-
   int dim = 1;
   void *val[] = {&dim};
   int number_of_curves;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
-	  					    val, 1, number_of_curves );
+    					          val, 1, number_of_curves );
   CHECK_ERR(rval);
   CHECK_EQUAL( 12 , number_of_curves );
   
-  // Get curve handles
+  //Get curve handles
   Range curves;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, curves );
@@ -100,6 +98,7 @@ void read_cube_curve_senses_test()
 
   // Establish GeomTopoTool instance needed to get curve data 
   moab::GeomTopoTool gt( mb, false );  
+  // Initialize vectors for sense checking
   std::vector<EntityHandle> surfs;
   std::vector<int> senses;  
   std::vector<int> known_surf_ids;
@@ -118,12 +117,11 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    //Clear reference data from previous curve
    known_surf_ids.clear();
    known_senses.clear();
-   //Load known curve-sense data
+   //Load known curve-sense ID data
    load_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
-
+   //Check that each surf and sense has a match in the references
    check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
   }
-
 }
 
 
@@ -131,11 +129,11 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
 {
     
     ErrorCode rval;
-
+    //Get the id_tag handle
     Tag id_tag;
     rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
     assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
-                      
+    //Load the ID for the EntHandle given to the function                  
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
     CHECK_ERR(rval);                        
@@ -176,6 +174,7 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
 
 }
 
+//Loads two vectors with reference curve and curve_sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
 {
 
@@ -263,7 +262,7 @@ void read_cube_surf_senses_test()
                              geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
   
-  // Check that the proper number of curves exist
+  // Check that the proper number of surfaces exist
   int dim = 2;
   void *val[] = {&dim};
   int number_of_curves;
@@ -272,13 +271,13 @@ void read_cube_surf_senses_test()
   CHECK_ERR(rval);
   CHECK_EQUAL( 6, number_of_curves );
   
-  // Get curve handles
+  // Get surface handles
   Range surfs;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, surfs );
   CHECK_ERR(rval);
 
-  // Establish GeomTopoTool instance needed to get curve data 
+  // Establish GeomTopoTool instance needed to get surf data 
   moab::GeomTopoTool gt( mb, false );  
   std::vector<EntityHandle> vols;
   std::vector<int> senses;  
@@ -294,10 +293,11 @@ for(unsigned int i = 0; i < surfs.size(); i++)
    // surface from the mesh
    gt.get_senses( surfs[i], vols, senses );
    CHECK_ERR(rval);
-
-   //Load known curve-sense data
+   //Clear previous reverence data
    known_vol_ids.clear();
    known_senses.clear();
+   // Load known surface-volume data 
+   // for this surface and check that it's correct
    load_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
    // Check sense information from the loaded mesh against 
    // reference sense information
@@ -307,10 +307,10 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 
 }
 
+//Loads reference surface to volume sense data into the reference vectors
 void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
-
   switch(surf_id)
   {
     case 1:
@@ -341,8 +341,8 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
     case 6:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
+
     break;
    }
-
 }
 


https://bitbucket.org/fathomteam/moab/commits/de1a4366f71c/
Changeset:   de1a4366f71c
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added a new file for sense checking and re-directed the ReadCGM sense tests to that file

Affected #:  2 files

diff --git a/MeshFiles/unittest/io/cylcube.sat b/MeshFiles/unittest/io/cylcube.sat
new file mode 100644
index 0000000..0b65976
--- /dev/null
+++ b/MeshFiles/unittest/io/cylcube.sat
@@ -0,0 +1,202 @@
+1900 0 2 0           
+10 Cubit 12.2 17 ACIS 19.0.2 Linux 24 Thu Feb  6 08:36:54 2014 
+1 9.9999999999999995e-07 1e-10 
+body $2 -1 -1 $-1 $3 $-1 $4 T 25 -5 -5 35 5 5 #
+body $5 -1 -1 $-1 $6 $-1 $-1 T -5 -5 -5 5 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $7 $-1 $0 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+lump $8 -1 -1 $-1 $-1 $9 $0 T 25 -5 -5 35 5 5 #
+transform $-1 -1 1 0 0 0 1 0 0 0 1 0 0 0 1 no_rotate no_reflect no_shear #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $10 $-1 $1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+lump $11 -1 -1 $-1 $-1 $12 $1 T -5 -5 -5 5 5 5 #
+simple-snl-attrib $-1 -1 $-1 $2 $0 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $13 $-1 $3 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+shell $-1 -1 -1 $-1 $-1 $-1 $14 $-1 $3 T 25 -5 -5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $5 $1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $15 $-1 $6 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+shell $-1 -1 -1 $-1 $-1 $-1 $16 $-1 $6 T -5 -5 -5 5 5 5 #
+simple-snl-attrib $-1 -1 $17 $8 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+face $18 -1 -1 $-1 $19 $20 $9 $-1 $21 forward single T 25 -5 5 35 5 5 F #
+simple-snl-attrib $-1 -1 $22 $11 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+face $23 -1 -1 $-1 $24 $25 $12 $-1 $26 forward single T -5 -5 -5 5 5 5 F #
+simple-snl-attrib $-1 -1 $27 $13 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 2 @5 GROUP @7 Group 2 0 7 1 2 618932362 0 0 0 0 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $28 $-1 $14 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+face $29 -1 -1 $-1 $30 $31 $9 $-1 $32 reversed single T 25 -5 -5 35 5 -5 F #
+loop $-1 -1 -1 $-1 $-1 $33 $14 T 25 -5 5 35 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 0 5 0 0 1 1 0 0 forward_v I I I I #
+simple-snl-attrib $-1 -1 $34 $15 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 2 @5 GROUP @7 Group 3 0 7 1 3 885205176 0 0 0 0 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $35 $-1 $16 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+face $36 -1 -1 $-1 $37 $38 $12 $-1 $39 forward single T -5 -5 -5 5 5 -5 F #
+loop $-1 -1 -1 $-1 $40 $41 $16 T -5 -5 -5 5 5 -5 unknown #
+cone-surface $-1 -1 -1 $-1 0 0 0 0 0 1 5 0 0 1 I I 0 1 5 forward I I I I #
+simple-snl-attrib $-1 -1 $-1 $17 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 7 @16 GRAPHICS_OPTIONS @14 geometry color @10 mesh color @19 geometry visibility @15 mesh visibility @11 render mode @11 transparent 0 6 4 4 1 1 0 0 #
+simple-snl-attrib $-1 -1 $42 $18 $14 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $43 $-1 $19 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+face $44 -1 -1 $-1 $45 $46 $9 $-1 $47 reversed single T 25 -5 -5 35 -5 5 F #
+loop $-1 -1 -1 $-1 $-1 $48 $19 T 25 -5 -5 35 5 -5 unknown #
+plane-surface $-1 -1 -1 $-1 30 0 -5 0 0 1 1 0 0 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $49 $50 $51 $52 forward $20 $-1 #
+simple-snl-attrib $-1 -1 $-1 $22 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 7 @16 GRAPHICS_OPTIONS @14 geometry color @10 mesh color @19 geometry visibility @15 mesh visibility @11 render mode @11 transparent 0 6 5 5 1 1 0 0 #
+simple-snl-attrib $-1 -1 $53 $23 $16 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $54 $-1 $24 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+face $55 -1 -1 $-1 $-1 $56 $12 $-1 $57 forward single T -5 -5 5 5 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $58 $24 T -5 -5 -5 5 5 -5 unknown #
+plane-surface $-1 -1 -1 $-1 0 0 -5 0 0 -1 -1 0 0 forward_v I I I I #
+loop $-1 -1 -1 $-1 $-1 $59 $16 T -5 -5 5 5 5 5 unknown #
+coedge $-1 -1 -1 $-1 $41 $41 $58 $60 reversed $25 $-1 #
+simple-snl-attrib $-1 -1 $-1 $28 $14 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $61 $29 $19 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $62 $-1 $30 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+face $63 -1 -1 $-1 $64 $65 $9 $-1 $66 reversed single T 25 -5 -5 25 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $67 $30 T 25 -5 -5 35 -5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 -5 0 0 1 0 0 0 1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $68 $69 $70 $71 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $72 $33 $73 $74 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $33 $72 $75 $76 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $77 $78 $33 $52 reversed $79 $-1 #
+edge $80 -1 -1 $-1 $81 -5 $82 5 $51 $83 forward @7 unknown T 35 -5 5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $35 $16 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $84 $36 $24 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $85 $-1 $37 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+loop $-1 -1 -1 $-1 $-1 $86 $37 T -5 -5 5 5 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 0 0 5 0 0 1 1 0 0 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $58 $58 $41 $60 forward $38 $-1 #
+coedge $-1 -1 -1 $-1 $59 $59 $86 $87 reversed $40 $-1 #
+edge $88 -1 -1 $-1 $89 0 $89 6.2831853071795862 $58 $90 forward @7 unknown T -5 -5 -5 5 5 -5 #
+simple-snl-attrib $-1 -1 $-1 $43 $19 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $91 $44 $30 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $92 $-1 $45 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+face $93 -1 -1 $-1 $94 $95 $9 $-1 $96 reversed single T 25 5 -5 35 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $97 $45 T 25 -5 -5 25 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 25 0 0 1 0 0 0 0 -1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $98 $75 $99 $100 forward $46 $-1 #
+coedge $-1 -1 -1 $-1 $101 $48 $98 $102 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $48 $101 $103 $104 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $78 $77 $48 $71 reversed $79 $-1 #
+edge $105 -1 -1 $-1 $106 -5 $107 5 $70 $108 forward @7 unknown T 35 -5 -5 35 5 -5 #
+coedge $-1 -1 -1 $-1 $50 $49 $109 $110 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $111 $112 $49 $74 reversed $95 $-1 #
+edge $113 -1 -1 $-1 $82 -5 $114 5 $73 $115 forward @7 unknown T 25 5 5 35 5 5 #
+coedge $-1 -1 -1 $-1 $67 $116 $50 $76 reversed $46 $-1 #
+edge $117 -1 -1 $-1 $118 -5 $81 5 $75 $119 forward @7 unknown T 25 -5 5 35 -5 5 #
+coedge $-1 -1 -1 $-1 $70 $51 $116 $120 forward $79 $-1 #
+coedge $-1 -1 -1 $-1 $51 $70 $111 $121 reversed $79 $-1 #
+loop $-1 -1 -1 $-1 $-1 $77 $94 T 35 -5 -5 35 5 5 unknown #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $122 $-1 $52 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+vertex $123 -1 -1 $-1 $52 $124 #
+vertex $125 -1 -1 $-1 $52 $126 #
+straight-curve $-1 -1 -1 $-1 35 0 5 0 1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $54 $24 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $127 $55 $37 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+coedge $-1 -1 -1 $-1 $86 $86 $59 $87 forward $56 $-1 #
+edge $128 -1 -1 $-1 $129 0 $129 6.2831853071795862 $86 $130 forward @7 unknown T -5 -5 5 5 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $131 $-1 $60 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 13 #
+vertex $132 -1 -1 $-1 $60 $133 #
+ellipse-curve $-1 -1 -1 $-1 0 0 -5 0 0 -1 5 0 0 1 I I #
+simple-snl-attrib $-1 -1 $-1 $62 $30 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $134 $63 $45 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $135 $-1 $64 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+face $136 -1 -1 $-1 $-1 $79 $9 $-1 $137 reversed single T 35 -5 -5 35 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $111 $64 T 25 5 -5 35 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 5 0 0 -1 0 0 0 -1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $138 $109 $112 $139 forward $65 $-1 #
+coedge $-1 -1 -1 $-1 $116 $67 $68 $102 reversed $46 $-1 #
+coedge $-1 -1 -1 $-1 $109 $138 $67 $100 reversed $65 $-1 #
+edge $140 -1 -1 $-1 $118 -5 $141 5 $99 $142 forward @7 unknown T 25 -5 -5 25 -5 5 #
+coedge $-1 -1 -1 $-1 $69 $68 $138 $143 forward $31 $-1 #
+edge $144 -1 -1 $-1 $107 -5 $141 5 $98 $145 forward @7 unknown T 25 -5 -5 35 -5 -5 #
+coedge $-1 -1 -1 $-1 $112 $111 $69 $104 reversed $95 $-1 #
+edge $146 -1 -1 $-1 $147 -5 $106 5 $103 $148 forward @7 unknown T 25 5 -5 35 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $149 $-1 $71 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+vertex $150 -1 -1 $-1 $71 $151 #
+vertex $152 -1 -1 $-1 $120 $153 #
+straight-curve $-1 -1 -1 $-1 35 0 -5 0 -1 0 I I #
+coedge $-1 -1 -1 $-1 $97 $99 $72 $110 reversed $65 $-1 #
+edge $154 -1 -1 $-1 $114 -5 $118 5 $109 $155 forward @7 unknown T 25 -5 5 25 5 5 #
+coedge $-1 -1 -1 $-1 $103 $73 $78 $121 forward $95 $-1 #
+coedge $-1 -1 -1 $-1 $73 $103 $97 $139 reversed $95 $-1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $156 $-1 $74 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+vertex $157 -1 -1 $-1 $74 $158 #
+straight-curve $-1 -1 -1 $-1 30 5 5 -1 0 0 I I #
+coedge $-1 -1 -1 $-1 $75 $98 $77 $120 reversed $46 $-1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $159 $-1 $76 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+vertex $160 -1 -1 $-1 $110 $161 #
+straight-curve $-1 -1 -1 $-1 30 -5 5 1 0 0 I I #
+edge $162 -1 -1 $-1 $81 -5 $107 5 $77 $163 forward @7 unknown T 35 -5 -5 35 -5 5 #
+edge $164 -1 -1 $-1 $82 -5 $106 5 $78 $165 forward @7 unknown T 35 5 -5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $80 $52 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $166 $-1 $81 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+point $-1 -1 -1 $-1 35 -5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $167 $-1 $82 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+point $-1 -1 -1 $-1 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $85 $37 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $168 $-1 $87 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 14 #
+vertex $169 -1 -1 $-1 $87 $170 #
+ellipse-curve $-1 -1 -1 $-1 0 0 5 0 0 1 5 0 0 1 I I #
+simple-snl-attrib $-1 -1 $-1 $88 $60 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 13 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $171 $-1 $89 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+point $-1 -1 -1 $-1 5 0 -5 #
+simple-snl-attrib $-1 -1 $-1 $92 $45 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $172 $93 $64 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $173 $-1 $94 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+plane-surface $-1 -1 -1 $-1 35 0 0 -1 0 0 0 0 1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $99 $97 $101 $143 reversed $65 $-1 #
+edge $174 -1 -1 $-1 $114 -5 $147 5 $112 $175 forward @7 unknown T 25 5 -5 25 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $176 $-1 $100 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+vertex $177 -1 -1 $-1 $143 $178 #
+straight-curve $-1 -1 -1 $-1 25 -5 0 0 0 -1 I I #
+edge $179 -1 -1 $-1 $141 -5 $147 5 $138 $180 forward @7 unknown T 25 -5 -5 25 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $181 $-1 $102 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+straight-curve $-1 -1 -1 $-1 30 -5 -5 -1 0 0 I I #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $182 $-1 $104 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+vertex $183 -1 -1 $-1 $104 $184 #
+straight-curve $-1 -1 -1 $-1 30 5 -5 1 0 0 I I #
+simple-snl-attrib $-1 -1 $-1 $105 $71 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $185 $-1 $106 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+point $-1 -1 -1 $-1 35 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $186 $-1 $107 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+point $-1 -1 -1 $-1 35 -5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $187 $-1 $110 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+straight-curve $-1 -1 -1 $-1 25 0 5 0 -1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $113 $74 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $188 $-1 $114 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+point $-1 -1 -1 $-1 25 5 5 #
+simple-snl-attrib $-1 -1 $-1 $117 $76 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $189 $-1 $118 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+point $-1 -1 -1 $-1 25 -5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $190 $-1 $120 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 10 #
+straight-curve $-1 -1 -1 $-1 35 -5 0 0 0 -1 I I #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $191 $-1 $121 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 12 #
+straight-curve $-1 -1 -1 $-1 35 5 0 0 0 -1 I I #
+simple-snl-attrib $-1 -1 $-1 $123 $81 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $125 $82 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $128 $87 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 14 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $192 $-1 $129 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 10 #
+point $-1 -1 -1 $-1 5 0 5 #
+simple-snl-attrib $-1 -1 $-1 $132 $89 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $135 $64 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $193 $136 $94 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $194 $-1 $139 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 11 #
+straight-curve $-1 -1 -1 $-1 25 5 0 0 0 -1 I I #
+simple-snl-attrib $-1 -1 $-1 $140 $100 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $195 $-1 $141 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+point $-1 -1 -1 $-1 25 -5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $196 $-1 $143 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+straight-curve $-1 -1 -1 $-1 25 0 -5 0 1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $144 $102 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $146 $104 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $197 $-1 $147 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+point $-1 -1 -1 $-1 25 5 -5 #
+simple-snl-attrib $-1 -1 $-1 $150 $106 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $152 $107 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $154 $110 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $157 $114 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $160 $118 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $162 $120 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 10 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $164 $121 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 12 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $169 $129 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 10 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $173 $94 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $-1 $174 $139 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 11 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $177 $141 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $179 $143 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $183 $147 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+End-of-ACIS-data 
\ No newline at end of file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 4f0896d..0b45b99 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -21,9 +21,9 @@ using namespace moab;
 
 
 #ifdef MESHDIR
-static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
 #else
-static const char input_cube[] = "/io/cube.sat";
+static const char input_cube[] = "/io/cylcube.sat";
 #endif
 
 // Function used to load the test file


https://bitbucket.org/fathomteam/moab/commits/241e0c4bbaa7/
Changeset:   241e0c4bbaa7
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Updated names of test functions; made a correction to a variable name in read_cylcube_surf_senses_test()

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 0b45b99..07713a9 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -42,8 +42,8 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
 int geom_id_by_handle( Interface* moab, const EntityHandle set );
 
 // List of tests in this file
-void read_cube_curve_senses_test();
-void read_cube_surf_senses_test();
+void read_cylcube_curve_senses_test();
+void read_cylcube_surf_senses_test();
 void delete_mesh_test();
 
 
@@ -51,8 +51,8 @@ int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
 
-  result += RUN_TEST(read_cube_curve_senses_test);  
-  result += RUN_TEST(read_cube_surf_senses_test);  
+  result += RUN_TEST(read_cylcube_curve_senses_test);  
+  result += RUN_TEST(read_cylcube_surf_senses_test);  
  
   return result;
 }
@@ -67,7 +67,7 @@ void read_file( Interface* moab, const char* input_file )
   CHECK_ERR(rval);
 }
 
-void read_cube_curve_senses_test()
+void read_cylcube_curve_senses_test()
 {
   ErrorCode rval;
   //Open the test file
@@ -248,7 +248,7 @@ void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int
 }
 
 ///SURFACE SENSE CHECKING
-void read_cube_surf_senses_test()
+void read_cylcube_surf_senses_test()
 {
   ErrorCode rval;
   //Open the test file
@@ -265,11 +265,11 @@ void read_cube_surf_senses_test()
   // Check that the proper number of surfaces exist
   int dim = 2;
   void *val[] = {&dim};
-  int number_of_curves;
+  int number_of_surfs;
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
-	  					    val, 1, number_of_curves );
+	  					    val, 1, number_of_surfs );
   CHECK_ERR(rval);
-  CHECK_EQUAL( 6, number_of_curves );
+  CHECK_EQUAL( 6, number_of_surfs );
   
   // Get surface handles
   Range surfs;


https://bitbucket.org/fathomteam/moab/commits/5e4262a61963/
Changeset:   5e4262a61963
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Updated reference information to match the new file

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 07713a9..0ec0db7 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -88,7 +88,7 @@ void read_cylcube_curve_senses_test()
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
     					          val, 1, number_of_curves );
   CHECK_ERR(rval);
-  CHECK_EQUAL( 12 , number_of_curves );
+  CHECK_EQUAL( 14, number_of_curves );
   
   //Get curve handles
   Range curves;
@@ -186,63 +186,72 @@ void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int
     case 1:
           surf_ids_out.push_back(1); surf_ids_out.push_back(6);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 2:
           surf_ids_out.push_back(1); surf_ids_out.push_back(5);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 3:
           surf_ids_out.push_back(1); surf_ids_out.push_back(4);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 4:
           surf_ids_out.push_back(1); surf_ids_out.push_back(3);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 5:
           surf_ids_out.push_back(2); surf_ids_out.push_back(6);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 6:
           surf_ids_out.push_back(2); surf_ids_out.push_back(3);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 7:
           surf_ids_out.push_back(2); surf_ids_out.push_back(4);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 8:
           surf_ids_out.push_back(2); surf_ids_out.push_back(5);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 9:
           surf_ids_out.push_back(3); surf_ids_out.push_back(4);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 10:
           surf_ids_out.push_back(3); surf_ids_out.push_back(6);
           senses_out.push_back(-1); senses_out.push_back(1);
+          break;
 
-    break;
     case 11:
           surf_ids_out.push_back(4); surf_ids_out.push_back(5);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
     case 12:
           surf_ids_out.push_back(5); surf_ids_out.push_back(6);
           senses_out.push_back(1); senses_out.push_back(-1);
+          break;
 
-    break;
+    case 13:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(-1); senses_out.push_back(1);
+      break;
+
+    case 14:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(9);
+      senses_out.push_back(-1); senses_out.push_back(1);
+      break;
   } 
 
 }
@@ -269,7 +278,7 @@ void read_cylcube_surf_senses_test()
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_surfs );
   CHECK_ERR(rval);
-  CHECK_EQUAL( 6, number_of_surfs );
+  CHECK_EQUAL( 9, number_of_surfs );
   
   // Get surface handles
   Range surfs;
@@ -316,33 +325,47 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
     case 1:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
+          break;
 
-    break;
     case 2:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
-
-    break;
+          break;
 
     case 3:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
+          break;
 
-    break;
     case 4:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
+          break;
 
-    break;
     case 5:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
-    break;
+          break;
+
     case 6:
           vol_ids_out.push_back(1);
           senses_out.push_back(1); 
+          break;
+
+    case 7:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(1);
+          break;
+  
+    case 8:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(1);
+          break;
 
-    break;
+    case 9:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(1);
+          break;
    }
 }
 


https://bitbucket.org/fathomteam/moab/commits/5dfe613e2539/
Changeset:   5dfe613e2539
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Updated sense settings to use macros in case the CGM convention ever changes again.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 0ec0db7..2dcda2e 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -12,6 +12,9 @@
 #include "InitCGMA.hpp"
 #include "GeometryQueryTool.hpp"
 
+#define SENSE_FORWARD 1
+#define SENSE_REVERSE -1 
+#define SENSE_UNKNOWN 0
 using namespace moab;
 
 #define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
@@ -185,72 +188,72 @@ void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int
   {
     case 1:
           surf_ids_out.push_back(1); surf_ids_out.push_back(6);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 2:
           surf_ids_out.push_back(1); surf_ids_out.push_back(5);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 3:
           surf_ids_out.push_back(1); surf_ids_out.push_back(4);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 4:
           surf_ids_out.push_back(1); surf_ids_out.push_back(3);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 5:
           surf_ids_out.push_back(2); surf_ids_out.push_back(6);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 6:
           surf_ids_out.push_back(2); surf_ids_out.push_back(3);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 7:
           surf_ids_out.push_back(2); surf_ids_out.push_back(4);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 8:
           surf_ids_out.push_back(2); surf_ids_out.push_back(5);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 9:
           surf_ids_out.push_back(3); surf_ids_out.push_back(4);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 10:
           surf_ids_out.push_back(3); surf_ids_out.push_back(6);
-          senses_out.push_back(-1); senses_out.push_back(1);
+          senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
           break;
 
     case 11:
           surf_ids_out.push_back(4); surf_ids_out.push_back(5);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 12:
           surf_ids_out.push_back(5); surf_ids_out.push_back(6);
-          senses_out.push_back(1); senses_out.push_back(-1);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
           break;
 
     case 13:
       surf_ids_out.push_back(7); surf_ids_out.push_back(8);
-      senses_out.push_back(-1); senses_out.push_back(1);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
       break;
 
     case 14:
       surf_ids_out.push_back(7); surf_ids_out.push_back(9);
-      senses_out.push_back(-1); senses_out.push_back(1);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
       break;
   } 
 
@@ -324,47 +327,47 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
   {
     case 1:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 2:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 3:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 4:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 5:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 6:
           vol_ids_out.push_back(1);
-          senses_out.push_back(1); 
+          senses_out.push_back(SENSE_FORWARD); 
           break;
 
     case 7:
           vol_ids_out.push_back(2);
-          senses_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD);
           break;
   
     case 8:
           vol_ids_out.push_back(2);
-          senses_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD);
           break;
 
     case 9:
           vol_ids_out.push_back(2);
-          senses_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD);
           break;
    }
 }


https://bitbucket.org/fathomteam/moab/commits/d31d5b268fe8/
Changeset:   d31d5b268fe8
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added new ReadCGM test file read_cgm_group_test.cpp. Included this in the /test/io Makefile.am

Affected #:  2 files

diff --git a/test/io/Makefile.am b/test/io/Makefile.am
index e9a73b3..61f932a 100644
--- a/test/io/Makefile.am
+++ b/test/io/Makefile.am
@@ -25,7 +25,8 @@ else
 endif
 
 if HAVE_CGM
-  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test read_cgm_connectivity_test
+  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test read_cgm_connectivity_test \
+             read_cgm_group_test
 else
   CGM_TEST = 
 endif
@@ -78,6 +79,8 @@ read_cgm_senses_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_senses_test.cp
 read_cgm_senses_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 read_cgm_connectivity_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_connectivity_test.cpp
 read_cgm_connectivity_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_group_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_group_test.cpp
+read_cgm_group_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 readutil_test_SOURCES = $(srcdir)/../TestUtil.hpp readutil_test.cpp
 cgns_test_SOURCES=$(srcdir)/../TestUtil.hpp cgns_test.cpp
 

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
new file mode 100644
index 0000000..5596880
--- /dev/null
+++ b/test/io/read_cgm_group_test.cpp
@@ -0,0 +1,51 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+#else
+static const char input_cube[] = "/io/cube.sat";
+#endif
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// List of tests in this file
+
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+ 
+  return result;
+}
+
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}


https://bitbucket.org/fathomteam/moab/commits/d224143bbebd/
Changeset:   d224143bbebd
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Added testing of groups and group names to read_cgm_group_test

Affected #:  1 file

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 5596880..04d4787 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -20,21 +20,32 @@ using namespace moab;
 
 
 #ifdef MESHDIR
-static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
 #else
-static const char input_cube[] = "/io/cube.sat";
+static const char input_cylcube[] = "/io/cylcube.sat";
 #endif
 
 // Function used to load the test file
 void read_file( Interface* moab, const char* input_file );
 
-// List of tests in this file
+//Function for getting entity ids
+int geom_id_by_handle( Interface* moab, const EntityHandle set );
+
+//Function for checking retrieved group data
+void check_group_data( std::vector<int> group_ids, std::vector<std::string> group_names, std::vector<int> group_ent_ids );
 
+//Function for loading all reference data
+void load_group_references( std::vector<int>& ids, std::vector<std::string>& names, std::vector<int>& ent_ids);
+
+// List of tests in this file
+void read_cylcube_groups_test();
 
 
 int main(int /* argc */, char** /* argv */)
 {
   int result = 0;
+
+  result+=RUN_TEST(read_cylcube_groups_test);
  
   return result;
 }
@@ -49,3 +60,126 @@ void read_file( Interface* moab, const char* input_file )
   ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR(rval);
 }
+
+void read_cylcube_groups_test()
+{
+
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cylcube);  
+
+  //Get (or create) the name and category tags
+  Tag name_tag, category_tag;
+
+  rval = mb->tag_get_handle( NAME_TAG_NAME, NAME_TAG_SIZE, MB_TYPE_OPAQUE,
+                             name_tag, moab::MB_TAG_SPARSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+
+  rval = mb->tag_get_handle( CATEGORY_TAG_NAME, CATEGORY_TAG_SIZE,
+                             MB_TYPE_OPAQUE, category_tag,
+                             moab::MB_TAG_SPARSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+
+  //Get the group entity handles
+  Range group_sets;
+  char query[] = "Group\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";   
+  //Has to be this way because of the way tags are created
+  void* val[] = {&query};
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &category_tag, val, 1, group_sets);
+  CHECK_ERR(rval);
+
+  std::vector<int> g_ids;
+  std::vector<std::string> g_names;
+  std::vector<int> g_ent_ids;
+  int j = 0;
+  for(Range::iterator i=group_sets.begin(); i!=group_sets.end(); i++)
+    {
+      int group_id = geom_id_by_handle( mb, *i );
+      g_ids.push_back(group_id);
+      //Get the group name
+      char group_name[NAME_TAG_SIZE+1];
+      rval = mb->tag_get_data( name_tag, &(*i), 1, &group_name);
+      CHECK_ERR(rval);
+      //Store group name
+      std::string temp(group_name);
+      g_names.push_back(temp);
+      //Ensure the group is named correctly
+      CHECK( strcmp( group_name, "Group 2") || strcmp(group_name, "Group 3"));
+      //Get all entities in the group
+      Range group_ents;
+      rval = mb->get_entities_by_type( *i, MBENTITYSET, group_ents, false);
+      CHECK_ERR(rval);
+      if( group_ents.size() != 1) CHECK(false);
+      int grp_ent_id = geom_id_by_handle( mb, group_ents[0] );
+      g_ent_ids.push_back(grp_ent_id);
+  
+    }
+  check_group_data(g_ids, g_names, g_ent_ids);
+}
+
+
+void check_group_data(std::vector<int> group_ids, std::vector<std::string> group_names, std::vector<int> group_ent_ids )
+{
+
+  //Initialize reference data
+  std::vector<int> group_ref_ids;
+  std::vector<std::string> group_ref_names;
+  std::vector<int> group_ref_ent_ids;
+  load_group_references( group_ref_ids, group_ref_names, group_ref_ent_ids );
+
+  // check that the correct number of entities were found
+  CHECK_EQUAL ( group_ref_ids.size(), group_ids.size() );
+  //  CHECK_EQUAL ( group_ref_names.size(), group_names.size() );  
+  CHECK_EQUAL ( group_ref_ent_ids.size(), group_ent_ids.size() );
+
+  //now make sure that each group has a matching group
+  for(unsigned int i=0 ; i<group_ids.size(); i++)
+    {
+      for(unsigned int j=0; j<group_ref_ids.size(); j++)
+	{
+          if( group_ids[i]==group_ref_ids[j]
+	      && group_names[i] ==  group_ref_names[j]
+              && group_ent_ids[i]==group_ref_ent_ids[j])
+	    {
+              group_ref_ids.erase(group_ref_ids.begin()+j);
+              group_ref_names.erase(group_ref_names.begin()+j);
+              group_ref_ent_ids.erase(group_ref_ent_ids.begin()+j);
+              continue;
+	    }
+	}
+    }
+
+  // Check sizes of reference vectors after matching
+  // (all should be zero)
+   int leftovers = group_ref_ids.size();
+  CHECK_EQUAL( 0, leftovers );
+  leftovers = group_ref_names.size();
+  CHECK_EQUAL( 0, leftovers );
+  leftovers = group_ref_ent_ids.size();
+  CHECK_EQUAL( 0, leftovers );
+}
+
+void load_group_references( std::vector<int>& ids, std::vector<std::string>& names, std::vector<int>& ent_ids )
+{
+  //First set of group info
+  names.push_back("Group 3"); ids.push_back(3); ent_ids.push_back(2);
+  
+  //Second set of group info
+  names.push_back("Group 2"); ids.push_back(2); ent_ids.push_back(1);
+}
+
+int geom_id_by_handle( Interface* moab, const EntityHandle set )
+{  
+    ErrorCode rval;
+    //Get the id_tag handle
+    Tag id_tag;
+    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
+    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    //Load the ID for the EntHandle given to the function                  
+    int id;
+    rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
+    CHECK_ERR(rval);                        
+    return id;
+ }


https://bitbucket.org/fathomteam/moab/commits/b01d729344cf/
Changeset:   b01d729344cf
Branch:      None
User:        pshriwise
Date:        2014-02-13 23:52:41
Summary:     Cleanup of read_cgm_group_test.cpp

Affected #:  1 file

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 04d4787..1357fb3 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -89,7 +89,7 @@ void read_cylcube_groups_test()
   void* val[] = {&query};
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &category_tag, val, 1, group_sets);
   CHECK_ERR(rval);
-
+  //Get group names and IDs
   std::vector<int> g_ids;
   std::vector<std::string> g_names;
   std::vector<int> g_ent_ids;
@@ -105,18 +105,16 @@ void read_cylcube_groups_test()
       //Store group name
       std::string temp(group_name);
       g_names.push_back(temp);
-      //Ensure the group is named correctly
-      CHECK( strcmp( group_name, "Group 2") || strcmp(group_name, "Group 3"));
       //Get all entities in the group
       Range group_ents;
-      rval = mb->get_entities_by_type( *i, MBENTITYSET, group_ents, false);
+      rval = mb->get_entities_by_type( *i, MBENTITYSET, group_ents, false );
       CHECK_ERR(rval);
       if( group_ents.size() != 1) CHECK(false);
       int grp_ent_id = geom_id_by_handle( mb, group_ents[0] );
       g_ent_ids.push_back(grp_ent_id);
   
     }
-  check_group_data(g_ids, g_names, g_ent_ids);
+  check_group_data( g_ids, g_names, g_ent_ids );
 }
 
 
@@ -131,7 +129,7 @@ void check_group_data(std::vector<int> group_ids, std::vector<std::string> group
 
   // check that the correct number of entities were found
   CHECK_EQUAL ( group_ref_ids.size(), group_ids.size() );
-  //  CHECK_EQUAL ( group_ref_names.size(), group_names.size() );  
+  CHECK_EQUAL ( group_ref_names.size(), group_names.size() );  
   CHECK_EQUAL ( group_ref_ent_ids.size(), group_ent_ids.size() );
 
   //now make sure that each group has a matching group


https://bitbucket.org/fathomteam/moab/commits/9032edc44c70/
Changeset:   9032edc44c70
Branch:      None
User:        pshriwise
Date:        2014-02-15 19:38:36
Summary:     Updated the ReadCGM group test to include conditions for a build w/ OCC.

Affected #:  2 files

diff --git a/MeshFiles/unittest/io/cylcube.stp b/MeshFiles/unittest/io/cylcube.stp
new file mode 100644
index 0000000..bc4ec64
--- /dev/null
+++ b/MeshFiles/unittest/io/cylcube.stp
@@ -0,0 +1,290 @@
+ISO-10303-21;
+HEADER;
+FILE_DESCRIPTION(('STEP AP214'),'1');
+FILE_NAME('/home/user/cylcube.stp','2014-02-15T18:13:39',(' '),(' '),'Spatial InterOp 3D',' ',' ');
+FILE_SCHEMA(('automotive_design'));
+ENDSEC;
+DATA;
+#1=PRODUCT_DEFINITION_CONTEXT('',#13,'design');
+#2=APPLICATION_PROTOCOL_DEFINITION('INTERNATIONAL STANDARD','automotive_design',1994,#13);
+#3=PRODUCT_CATEGORY_RELATIONSHIP('NONE','NONE',#14,#15);
+#4=SHAPE_DEFINITION_REPRESENTATION(#16,#17);
+#5=PRODUCT_DEFINITION_CONTEXT('',#18,'design');
+#6=APPLICATION_PROTOCOL_DEFINITION('INTERNATIONAL STANDARD','automotive_design',1994,#18);
+#7=PRODUCT_CATEGORY_RELATIONSHIP('NONE','NONE',#19,#20);
+#8=SHAPE_DEFINITION_REPRESENTATION(#21,#22);
+#9= (GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#25))GLOBAL_UNIT_ASSIGNED_CONTEXT((#27,#28,#29))REPRESENTATION_CONTEXT('NONE','WORKSPACE'));
+#13=APPLICATION_CONTEXT(' ');
+#14=PRODUCT_CATEGORY('part','NONE');
+#15=PRODUCT_RELATED_PRODUCT_CATEGORY('detail',' ',(#31));
+#16=PRODUCT_DEFINITION_SHAPE('NONE','NONE',#32);
+#17=ADVANCED_BREP_SHAPE_REPRESENTATION('1',(#33,#34),#9);
+#18=APPLICATION_CONTEXT(' ');
+#19=PRODUCT_CATEGORY('part','NONE');
+#20=PRODUCT_RELATED_PRODUCT_CATEGORY('detail',' ',(#35));
+#21=PRODUCT_DEFINITION_SHAPE('NONE','NONE',#36);
+#22=ADVANCED_BREP_SHAPE_REPRESENTATION('2',(#37,#38),#9);
+#25=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-06),#27,'','');
+#27= (CONVERSION_BASED_UNIT('MILLIMETRE',#41)LENGTH_UNIT()NAMED_UNIT(#44));
+#28= (NAMED_UNIT(#46)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.));
+#29= (NAMED_UNIT(#46)SOLID_ANGLE_UNIT()SI_UNIT($,.STERADIAN.));
+#31=PRODUCT('1','1','PART-1-DESC',(#52));
+#32=PRODUCT_DEFINITION('NONE','NONE',#53,#1);
+#33=MANIFOLD_SOLID_BREP('1',#54);
+#34=AXIS2_PLACEMENT_3D('',#55,#56,#57);
+#35=PRODUCT('2','2','PART-2-DESC',(#58));
+#36=PRODUCT_DEFINITION('NONE','NONE',#59,#5);
+#37=MANIFOLD_SOLID_BREP('2',#60);
+#38=AXIS2_PLACEMENT_3D('',#61,#62,#63);
+#41=LENGTH_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0),#64);
+#44=DIMENSIONAL_EXPONENTS(1.0,0.0,0.0,0.0,0.0,0.0,0.0);
+#46=DIMENSIONAL_EXPONENTS(0.0,0.0,0.0,0.0,0.0,0.0,0.0);
+#52=PRODUCT_CONTEXT('',#13,'mechanical');
+#53=PRODUCT_DEFINITION_FORMATION_WITH_SPECIFIED_SOURCE(' ','NONE',#31,.NOT_KNOWN.);
+#54=CLOSED_SHELL('',(#65,#66,#67,#68,#69,#70));
+#55=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#56=DIRECTION('',(0.0,0.0,1.0));
+#57=DIRECTION('',(1.0,0.0,0.0));
+#58=PRODUCT_CONTEXT('',#18,'mechanical');
+#59=PRODUCT_DEFINITION_FORMATION_WITH_SPECIFIED_SOURCE(' ','NONE',#35,.NOT_KNOWN.);
+#60=CLOSED_SHELL('',(#71,#72,#73,#74));
+#61=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#62=DIRECTION('',(0.0,0.0,1.0));
+#63=DIRECTION('',(1.0,0.0,0.0));
+#64= (NAMED_UNIT(#44)LENGTH_UNIT()SI_UNIT(.MILLI.,.METRE.));
+#65=ADVANCED_FACE('',(#76),#77,.T.);
+#66=ADVANCED_FACE('',(#78),#79,.F.);
+#67=ADVANCED_FACE('',(#80),#81,.F.);
+#68=ADVANCED_FACE('',(#82),#83,.F.);
+#69=ADVANCED_FACE('',(#84),#85,.F.);
+#70=ADVANCED_FACE('',(#86),#87,.F.);
+#71=ADVANCED_FACE('',(#88),#89,.T.);
+#72=ADVANCED_FACE('',(#90),#91,.T.);
+#73=ADVANCED_FACE('',(#92),#93,.T.);
+#74=ADVANCED_FACE('',(#94),#95,.T.);
+#76=FACE_OUTER_BOUND('',#96,.T.);
+#77=PLANE('',#97);
+#78=FACE_OUTER_BOUND('',#98,.T.);
+#79=PLANE('',#99);
+#80=FACE_OUTER_BOUND('',#100,.T.);
+#81=PLANE('',#101);
+#82=FACE_OUTER_BOUND('',#102,.T.);
+#83=PLANE('',#103);
+#84=FACE_OUTER_BOUND('',#104,.T.);
+#85=PLANE('',#105);
+#86=FACE_OUTER_BOUND('',#106,.T.);
+#87=PLANE('',#107);
+#88=FACE_OUTER_BOUND('',#108,.T.);
+#89=CYLINDRICAL_SURFACE('',#109,5.0);
+#90=FACE_OUTER_BOUND('',#110,.T.);
+#91=CYLINDRICAL_SURFACE('',#111,5.0);
+#92=FACE_OUTER_BOUND('',#112,.T.);
+#93=PLANE('',#113);
+#94=FACE_OUTER_BOUND('',#114,.T.);
+#95=PLANE('',#115);
+#96=EDGE_LOOP('',(#116,#117,#118,#119));
+#97=AXIS2_PLACEMENT_3D('',#120,#121,#122);
+#98=EDGE_LOOP('',(#123,#124,#125,#126));
+#99=AXIS2_PLACEMENT_3D('',#127,#128,#129);
+#100=EDGE_LOOP('',(#130,#131,#132,#133));
+#101=AXIS2_PLACEMENT_3D('',#134,#135,#136);
+#102=EDGE_LOOP('',(#137,#138,#139,#140));
+#103=AXIS2_PLACEMENT_3D('',#141,#142,#143);
+#104=EDGE_LOOP('',(#144,#145,#146,#147));
+#105=AXIS2_PLACEMENT_3D('',#148,#149,#150);
+#106=EDGE_LOOP('',(#151,#152,#153,#154));
+#107=AXIS2_PLACEMENT_3D('',#155,#156,#157);
+#108=EDGE_LOOP('',(#158,#159,#160,#161));
+#109=AXIS2_PLACEMENT_3D('',#162,#163,#164);
+#110=EDGE_LOOP('',(#165,#166,#167,#168));
+#111=AXIS2_PLACEMENT_3D('',#169,#170,#171);
+#112=EDGE_LOOP('',(#172,#173));
+#113=AXIS2_PLACEMENT_3D('',#174,#175,#176);
+#114=EDGE_LOOP('',(#177,#178));
+#115=AXIS2_PLACEMENT_3D('',#179,#180,#181);
+#116=ORIENTED_EDGE('',*,*,#182,.T.);
+#117=ORIENTED_EDGE('',*,*,#183,.T.);
+#118=ORIENTED_EDGE('',*,*,#184,.T.);
+#119=ORIENTED_EDGE('',*,*,#185,.T.);
+#120=CARTESIAN_POINT('',(30.0,0.0,5.0));
+#121=DIRECTION('',(0.0,0.0,1.0));
+#122=DIRECTION('',(1.0,0.0,0.0));
+#123=ORIENTED_EDGE('',*,*,#186,.T.);
+#124=ORIENTED_EDGE('',*,*,#187,.T.);
+#125=ORIENTED_EDGE('',*,*,#188,.T.);
+#126=ORIENTED_EDGE('',*,*,#189,.T.);
+#127=CARTESIAN_POINT('',(30.0,0.0,-5.0));
+#128=DIRECTION('',(0.0,0.0,1.0));
+#129=DIRECTION('',(1.0,0.0,0.0));
+#130=ORIENTED_EDGE('',*,*,#190,.T.);
+#131=ORIENTED_EDGE('',*,*,#187,.F.);
+#132=ORIENTED_EDGE('',*,*,#191,.F.);
+#133=ORIENTED_EDGE('',*,*,#185,.F.);
+#134=CARTESIAN_POINT('',(30.0,-5.0,0.0));
+#135=DIRECTION('',(0.0,1.0,0.0));
+#136=DIRECTION('',(0.0,0.0,1.0));
+#137=ORIENTED_EDGE('',*,*,#192,.T.);
+#138=ORIENTED_EDGE('',*,*,#188,.F.);
+#139=ORIENTED_EDGE('',*,*,#190,.F.);
+#140=ORIENTED_EDGE('',*,*,#184,.F.);
+#141=CARTESIAN_POINT('',(25.0,0.0,0.0));
+#142=DIRECTION('',(1.0,0.0,0.0));
+#143=DIRECTION('',(0.0,0.0,-1.0));
+#144=ORIENTED_EDGE('',*,*,#193,.T.);
+#145=ORIENTED_EDGE('',*,*,#189,.F.);
+#146=ORIENTED_EDGE('',*,*,#192,.F.);
+#147=ORIENTED_EDGE('',*,*,#183,.F.);
+#148=CARTESIAN_POINT('',(30.0,5.0,0.0));
+#149=DIRECTION('',(0.0,-1.0,0.0));
+#150=DIRECTION('',(0.0,0.0,-1.0));
+#151=ORIENTED_EDGE('',*,*,#191,.T.);
+#152=ORIENTED_EDGE('',*,*,#186,.F.);
+#153=ORIENTED_EDGE('',*,*,#193,.F.);
+#154=ORIENTED_EDGE('',*,*,#182,.F.);
+#155=CARTESIAN_POINT('',(35.0,0.0,0.0));
+#156=DIRECTION('',(-1.0,0.0,0.0));
+#157=DIRECTION('',(0.0,0.0,1.0));
+#158=ORIENTED_EDGE('',*,*,#194,.F.);
+#159=ORIENTED_EDGE('',*,*,#195,.F.);
+#160=ORIENTED_EDGE('',*,*,#196,.F.);
+#161=ORIENTED_EDGE('',*,*,#197,.F.);
+#162=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#163=DIRECTION('',(0.0,0.0,1.0));
+#164=DIRECTION('',(1.0,0.0,0.0));
+#165=ORIENTED_EDGE('',*,*,#194,.T.);
+#166=ORIENTED_EDGE('',*,*,#198,.F.);
+#167=ORIENTED_EDGE('',*,*,#196,.T.);
+#168=ORIENTED_EDGE('',*,*,#199,.F.);
+#169=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#170=DIRECTION('',(0.0,0.0,1.0));
+#171=DIRECTION('',(1.0,0.0,0.0));
+#172=ORIENTED_EDGE('',*,*,#199,.T.);
+#173=ORIENTED_EDGE('',*,*,#195,.T.);
+#174=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#175=DIRECTION('',(0.0,0.0,-1.0));
+#176=DIRECTION('',(-1.0,0.0,0.0));
+#177=ORIENTED_EDGE('',*,*,#197,.T.);
+#178=ORIENTED_EDGE('',*,*,#198,.T.);
+#179=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#180=DIRECTION('',(0.0,0.0,1.0));
+#181=DIRECTION('',(1.0,0.0,0.0));
+#182=EDGE_CURVE('',#200,#201,#202,.T.);
+#183=EDGE_CURVE('',#201,#203,#204,.T.);
+#184=EDGE_CURVE('',#203,#205,#206,.T.);
+#185=EDGE_CURVE('',#205,#200,#207,.T.);
+#186=EDGE_CURVE('',#208,#209,#210,.T.);
+#187=EDGE_CURVE('',#209,#211,#212,.T.);
+#188=EDGE_CURVE('',#211,#213,#214,.T.);
+#189=EDGE_CURVE('',#213,#208,#215,.T.);
+#190=EDGE_CURVE('',#205,#211,#216,.T.);
+#191=EDGE_CURVE('',#200,#209,#217,.T.);
+#192=EDGE_CURVE('',#203,#213,#218,.T.);
+#193=EDGE_CURVE('',#201,#208,#219,.T.);
+#194=EDGE_CURVE('',#220,#221,#222,.T.);
+#195=EDGE_CURVE('',#223,#220,#224,.T.);
+#196=EDGE_CURVE('',#225,#223,#226,.T.);
+#197=EDGE_CURVE('',#221,#225,#227,.T.);
+#198=EDGE_CURVE('',#225,#221,#228,.T.);
+#199=EDGE_CURVE('',#220,#223,#229,.T.);
+#200=VERTEX_POINT('',#230);
+#201=VERTEX_POINT('',#231);
+#202=LINE('',#232,#233);
+#203=VERTEX_POINT('',#234);
+#204=LINE('',#235,#236);
+#205=VERTEX_POINT('',#237);
+#206=LINE('',#238,#239);
+#207=LINE('',#240,#241);
+#208=VERTEX_POINT('',#242);
+#209=VERTEX_POINT('',#243);
+#210=LINE('',#244,#245);
+#211=VERTEX_POINT('',#246);
+#212=LINE('',#247,#248);
+#213=VERTEX_POINT('',#249);
+#214=LINE('',#250,#251);
+#215=LINE('',#252,#253);
+#216=LINE('',#254,#255);
+#217=LINE('',#256,#257);
+#218=LINE('',#258,#259);
+#219=LINE('',#260,#261);
+#220=VERTEX_POINT('',#262);
+#221=VERTEX_POINT('',#263);
+#222=LINE('',#264,#265);
+#223=VERTEX_POINT('',#266);
+#224=CIRCLE('',#267,5.0);
+#225=VERTEX_POINT('',#268);
+#226=LINE('',#269,#270);
+#227=CIRCLE('',#271,5.0);
+#228=CIRCLE('',#272,5.0);
+#229=CIRCLE('',#273,5.0);
+#230=CARTESIAN_POINT('',(35.0,-5.0,5.0));
+#231=CARTESIAN_POINT('',(35.0,5.0,5.0));
+#232=CARTESIAN_POINT('',(35.0,0.0,5.0));
+#233=VECTOR('',#274,1.0);
+#234=CARTESIAN_POINT('',(25.0,5.0,5.0));
+#235=CARTESIAN_POINT('',(30.0,5.0,5.0));
+#236=VECTOR('',#275,1.0);
+#237=CARTESIAN_POINT('',(25.0,-5.0,5.0));
+#238=CARTESIAN_POINT('',(25.0,0.0,5.0));
+#239=VECTOR('',#276,1.0);
+#240=CARTESIAN_POINT('',(30.0,-5.0,5.0));
+#241=VECTOR('',#277,1.0);
+#242=CARTESIAN_POINT('',(35.0,5.0,-5.0));
+#243=CARTESIAN_POINT('',(35.0,-5.0,-5.0));
+#244=CARTESIAN_POINT('',(35.0,0.0,-5.0));
+#245=VECTOR('',#278,1.0);
+#246=CARTESIAN_POINT('',(25.0,-5.0,-5.0));
+#247=CARTESIAN_POINT('',(30.0,-5.0,-5.0));
+#248=VECTOR('',#279,1.0);
+#249=CARTESIAN_POINT('',(25.0,5.0,-5.0));
+#250=CARTESIAN_POINT('',(25.0,0.0,-5.0));
+#251=VECTOR('',#280,1.0);
+#252=CARTESIAN_POINT('',(30.0,5.0,-5.0));
+#253=VECTOR('',#281,1.0);
+#254=CARTESIAN_POINT('',(25.0,-5.0,0.0));
+#255=VECTOR('',#282,1.0);
+#256=CARTESIAN_POINT('',(35.0,-5.0,0.0));
+#257=VECTOR('',#283,1.0);
+#258=CARTESIAN_POINT('',(25.0,5.0,0.0));
+#259=VECTOR('',#284,1.0);
+#260=CARTESIAN_POINT('',(35.0,5.0,0.0));
+#261=VECTOR('',#285,1.0);
+#262=CARTESIAN_POINT('',(5.0,0.0,-5.0));
+#263=CARTESIAN_POINT('',(5.0,0.0,5.0));
+#264=CARTESIAN_POINT('',(5.0,-6.12303176911189E-16,0.0));
+#265=VECTOR('',#286,1.0);
+#266=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,-5.0));
+#267=AXIS2_PLACEMENT_3D('',#287,#288,#289);
+#268=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,5.0));
+#269=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,0.0));
+#270=VECTOR('',#290,1.0);
+#271=AXIS2_PLACEMENT_3D('',#291,#292,#293);
+#272=AXIS2_PLACEMENT_3D('',#294,#295,#296);
+#273=AXIS2_PLACEMENT_3D('',#297,#298,#299);
+#274=DIRECTION('',(0.0,1.0,0.0));
+#275=DIRECTION('',(-1.0,0.0,0.0));
+#276=DIRECTION('',(0.0,-1.0,0.0));
+#277=DIRECTION('',(1.0,0.0,0.0));
+#278=DIRECTION('',(0.0,-1.0,0.0));
+#279=DIRECTION('',(-1.0,0.0,0.0));
+#280=DIRECTION('',(0.0,1.0,0.0));
+#281=DIRECTION('',(1.0,0.0,0.0));
+#282=DIRECTION('',(0.0,0.0,-1.0));
+#283=DIRECTION('',(0.0,0.0,-1.0));
+#284=DIRECTION('',(0.0,0.0,-1.0));
+#285=DIRECTION('',(0.0,0.0,-1.0));
+#286=DIRECTION('',(0.0,0.0,1.0));
+#287=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#288=DIRECTION('',(0.0,0.0,-1.0));
+#289=DIRECTION('',(1.0,0.0,0.0));
+#290=DIRECTION('',(-0.0,-0.0,-1.0));
+#291=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#292=DIRECTION('',(0.0,0.0,1.0));
+#293=DIRECTION('',(1.0,0.0,0.0));
+#294=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#295=DIRECTION('',(0.0,0.0,1.0));
+#296=DIRECTION('',(1.0,0.0,0.0));
+#297=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#298=DIRECTION('',(0.0,0.0,-1.0));
+#299=DIRECTION('',(1.0,0.0,0.0));
+ENDSEC;
+END-ISO-10303-21;

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 1357fb3..4148434 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -20,9 +20,17 @@ using namespace moab;
 
 
 #ifdef MESHDIR
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
+#else
 static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
+#endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = "cylcube.stp";
 #else
-static const char input_cylcube[] = "/io/cylcube.sat";
+static const char input_cylcube[] = "cylcube.sat";
+#endif
 #endif
 
 // Function used to load the test file
@@ -121,6 +129,17 @@ void read_cylcube_groups_test()
 void check_group_data(std::vector<int> group_ids, std::vector<std::string> group_names, std::vector<int> group_ent_ids )
 {
 
+  // Step files do not contain group data, MOAB shouldn't return errors when trying to access
+  // this data but there shouldn't be any found.
+#ifdef HAVE_OCC_STEP
+  int num_g_ids = group_ids.size();
+  int num_g_names = group_names.size();
+
+  CHECK_EQUAL( 0, num_g_ids );
+  CHECK_EQUAL( 0, num_g_names );
+#else
+
+
   //Initialize reference data
   std::vector<int> group_ref_ids;
   std::vector<std::string> group_ref_names;
@@ -157,6 +176,7 @@ void check_group_data(std::vector<int> group_ids, std::vector<std::string> group
   CHECK_EQUAL( 0, leftovers );
   leftovers = group_ref_ent_ids.size();
   CHECK_EQUAL( 0, leftovers );
+#endif
 }
 
 void load_group_references( std::vector<int>& ids, std::vector<std::string>& names, std::vector<int>& ent_ids )


https://bitbucket.org/fathomteam/moab/commits/91be9294b908/
Changeset:   91be9294b908
Branch:      None
User:        pshriwise
Date:        2014-02-15 20:26:37
Summary:     Added surface to volume sense reference data function for the cylcube step file. Updated the file name for occ builds.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 2dcda2e..3bce847 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -24,17 +24,28 @@ using namespace moab;
 
 
 #ifdef MESHDIR
-static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
 #else
-static const char input_cube[] = "/io/cylcube.sat";
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
 #endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = "cylcube.stp";
+#else
+static const char input_cylcube[] = "cylcube.sat";
+#endif
+#endif
+
 
 // Function used to load the test file
 void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_occ_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 
 // the model to reference information
@@ -76,7 +87,7 @@ void read_cylcube_curve_senses_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
   
   //Get all curve handles
   Tag geom_tag;
@@ -91,8 +102,15 @@ void read_cylcube_curve_senses_test()
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
     					          val, 1, number_of_curves );
   CHECK_ERR(rval);
+  //Step format adds a surface on the barrel of the cylinder.
+  //This created 4 extra surfaces in comparison to the .sat format from Cubit. 
+  //(New surface breaks the barrel of the cylinder into two half-pipes)
+#ifdef HAVE_OCC_STEP
+  CHECK_EQUAL( 18, number_of_curves );
+#else
   CHECK_EQUAL( 14, number_of_curves );
-  
+#endif
+
   //Get curve handles
   Range curves;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
@@ -266,7 +284,7 @@ void read_cylcube_surf_senses_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
   
   //Get geometry tag for gathering surface information from the mesh
   Tag geom_tag;
@@ -281,8 +299,13 @@ void read_cylcube_surf_senses_test()
   rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
 	  					    val, 1, number_of_surfs );
   CHECK_ERR(rval);
+  //Step format adds a surface on barrel of the cylinder.
+  // (Breaks it into two half-pipes)
+#ifdef HAVE_OCC_STEP
+  CHECK_EQUAL( 10, number_of_surfs );
+#else
   CHECK_EQUAL( 9, number_of_surfs );
-  
+#endif
   // Get surface handles
   Range surfs;
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
@@ -310,7 +333,11 @@ for(unsigned int i = 0; i < surfs.size(); i++)
    known_senses.clear();
    // Load known surface-volume data 
    // for this surface and check that it's correct
-   load_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+#ifdef HAV_OCC_STEP
+   load_occ_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+#else
+   load_cubit_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+#endif
    // Check sense information from the loaded mesh against 
    // reference sense information
    check_sense_data( mb, vols, senses, known_vol_ids, known_senses );
@@ -320,7 +347,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)
@@ -372,3 +399,61 @@ void load_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>&
    }
 }
 
+//Loads reference surface to volume sense data into the reference vectors
+void load_occ_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+
+  int surf_id = geom_id_by_handle( moab, surf );
+  switch(surf_id)
+  {
+    case 1:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 2:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 3:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 4:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 5:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 6:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 7:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+  
+    case 8:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 9:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 10:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+   }
+}
+


https://bitbucket.org/fathomteam/moab/commits/214a488501fa/
Changeset:   214a488501fa
Branch:      None
User:        pshriwise
Date:        2014-02-15 20:31:49
Summary:     Removed redundant prototype for load_cubit_vol_sense_data.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 3bce847..0c0faa2 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -44,7 +44,6 @@ void read_file( Interface* moab, const char* input_file );
 // Functions containing known sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
 void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
-void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 void load_occ_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 


https://bitbucket.org/fathomteam/moab/commits/739cf67f2313/
Changeset:   739cf67f2313
Branch:      None
User:        pshriwise
Date:        2014-02-15 20:33:58
Summary:     Changed function name from load_*_vol_sense_data to load_*_surf_sense_data

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 0c0faa2..d636e24 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -43,8 +43,8 @@ void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
 void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
-void load_occ_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_cubit_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_occ_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 
 // the model to reference information
@@ -333,9 +333,9 @@ for(unsigned int i = 0; i < surfs.size(); i++)
    // Load known surface-volume data 
    // for this surface and check that it's correct
 #ifdef HAV_OCC_STEP
-   load_occ_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   load_occ_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #else
-   load_cubit_vol_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   load_cubit_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #endif
    // Check sense information from the loaded mesh against 
    // reference sense information
@@ -346,7 +346,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+void load_cubit_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)
@@ -399,7 +399,7 @@ void load_cubit_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_occ_vol_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+void load_occ_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)


https://bitbucket.org/fathomteam/moab/commits/c661c87b96d7/
Changeset:   c661c87b96d7
Branch:      None
User:        pshriwise
Date:        2014-02-15 20:41:25
Summary:     Updated name of several load reference functions

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index d636e24..c52e14e 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -42,8 +42,8 @@ static const char input_cylcube[] = "cylcube.sat";
 void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
-void load_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-void load_cubit_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_sat_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 void load_occ_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 
@@ -138,7 +138,7 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    known_surf_ids.clear();
    known_senses.clear();
    //Load known curve-sense ID data
-   load_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   load_sat_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
    //Check that each surf and sense has a match in the references
    check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
   }
@@ -195,7 +195,7 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
 }
 
 //Loads two vectors with reference curve and curve_sense data
-void load_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+void load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
 {
 
   int curve_id = geom_id_by_handle( moab, curve );
@@ -335,7 +335,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 #ifdef HAV_OCC_STEP
    load_occ_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #else
-   load_cubit_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   load_sat_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #endif
    // Check sense information from the loaded mesh against 
    // reference sense information
@@ -346,7 +346,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_cubit_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)


https://bitbucket.org/fathomteam/moab/commits/6164b6d6c84e/
Changeset:   6164b6d6c84e
Branch:      None
User:        pshriwise
Date:        2014-02-15 20:53:44
Summary:     Added curve sense reference information function for step format.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index c52e14e..2be31d9 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -43,8 +43,9 @@ void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
 void load_sat_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+void load_stp_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
 void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
-void load_occ_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+void load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 
 // the model to reference information
@@ -138,7 +139,12 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    known_surf_ids.clear();
    known_senses.clear();
    //Load known curve-sense ID data
+#ifdef HAVE_OCC_STEP
+   load_stp_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+#else
    load_sat_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+#endif
+
    //Check that each surf and sense has a match in the references
    check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
   }
@@ -276,6 +282,104 @@ void load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector
 
 }
 
+//Loads two vectors with reference curve and curve_sense data
+void load_stp_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+{
+
+  int curve_id = geom_id_by_handle( moab, curve );
+
+
+  switch(curve_id)
+  {
+    case 1:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 2:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 3:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 4:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 5:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 6:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 7:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 8:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 9:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 10:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 11:
+          surf_ids_out.push_back(4); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 12:
+          surf_ids_out.push_back(5); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 13:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+
+    case 14:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(9);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 15:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 16:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(10);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 17:
+      surf_ids_out.push_back(8); surf_ids_out.push_back(10);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 18:
+      surf_ids_out.push_back(8); surf_ids_out.push_back(9);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+  } 
+
+}
+
 ///SURFACE SENSE CHECKING
 void read_cylcube_surf_senses_test()
 {
@@ -333,7 +437,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
    // Load known surface-volume data 
    // for this surface and check that it's correct
 #ifdef HAV_OCC_STEP
-   load_occ_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   load_stp_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #else
    load_sat_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
 #endif
@@ -399,7 +503,7 @@ void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<i
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_occ_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+void load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)


https://bitbucket.org/fathomteam/moab/commits/de01bb363024/
Changeset:   de01bb363024
Branch:      None
User:        pshriwise
Date:        2014-02-15 21:12:54
Summary:     Added failure conditions to reference loading functions in ReadCGM senses test.

If the correct surface id isn't found in the reference data, the function will return MB_FAILURE.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 2be31d9..499bfa3 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -42,10 +42,10 @@ static const char input_cylcube[] = "cylcube.sat";
 void read_file( Interface* moab, const char* input_file );
 
 // Functions containing known sense data
-void load_sat_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-void load_stp_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
-void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
-void load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+ErrorCode load_sat_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+ErrorCode load_stp_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+ErrorCode load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+ErrorCode load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
 
 // Functions used to compare sense information found in 
 // the model to reference information
@@ -140,9 +140,11 @@ for(unsigned int i = 0; i < curves.size() ; i++)
    known_senses.clear();
    //Load known curve-sense ID data
 #ifdef HAVE_OCC_STEP
-   load_stp_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   rval = load_stp_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   CHECK_ERR(rval);
 #else
-   load_sat_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   rval = load_sat_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   CHECK_ERR(rval);
 #endif
 
    //Check that each surf and sense has a match in the references
@@ -201,12 +203,10 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
 }
 
 //Loads two vectors with reference curve and curve_sense data
-void load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+ErrorCode load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
 {
 
   int curve_id = geom_id_by_handle( moab, curve );
-
-
   switch(curve_id)
   {
     case 1:
@@ -278,17 +278,18 @@ void load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector
       surf_ids_out.push_back(7); surf_ids_out.push_back(9);
       senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
       break;
-  } 
+    default:
+          return MB_FAILURE;
 
+  } 
+  return MB_SUCCESS;
 }
 
 //Loads two vectors with reference curve and curve_sense data
-void load_stp_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+ErrorCode load_stp_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
 {
 
   int curve_id = geom_id_by_handle( moab, curve );
-
-
   switch(curve_id)
   {
     case 1:
@@ -376,8 +377,11 @@ void load_stp_curve_sense_data( Interface* moab, EntityHandle curve, std::vector
       surf_ids_out.push_back(8); surf_ids_out.push_back(9);
       senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
       break;
-  } 
+    default:
+          return MB_FAILURE;
 
+  } 
+  return MB_SUCCESS;
 }
 
 ///SURFACE SENSE CHECKING
@@ -436,10 +440,12 @@ for(unsigned int i = 0; i < surfs.size(); i++)
    known_senses.clear();
    // Load known surface-volume data 
    // for this surface and check that it's correct
-#ifdef HAV_OCC_STEP
-   load_stp_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+#ifdef HAVE_OCC_STEP
+   rval = load_stp_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   CHECK_ERR(rval);
 #else
-   load_sat_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   rval = load_sat_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   CHECK_ERR(rval);
 #endif
    // Check sense information from the loaded mesh against 
    // reference sense information
@@ -450,7 +456,7 @@ for(unsigned int i = 0; i < surfs.size(); i++)
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+ErrorCode load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)
@@ -499,11 +505,15 @@ void load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<i
           vol_ids_out.push_back(2);
           senses_out.push_back(SENSE_FORWARD);
           break;
+    default:
+          return MB_FAILURE;
+
    }
+  return MB_SUCCESS;
 }
 
 //Loads reference surface to volume sense data into the reference vectors
-void load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+ErrorCode load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
 
   int surf_id = geom_id_by_handle( moab, surf );
   switch(surf_id)
@@ -557,6 +567,10 @@ void load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<i
           vol_ids_out.push_back(2);
           senses_out.push_back(SENSE_FORWARD);
           break;
+    default:
+      std::cout << "Failure to find surface sense reference data. Returning failure..." << std::endl;
+          return MB_FAILURE;
    }
+  return MB_SUCCESS;
 }
 


https://bitbucket.org/fathomteam/moab/commits/877a7c39f0a1/
Changeset:   877a7c39f0a1
Branch:      None
User:        pshriwise
Date:        2014-02-15 21:23:57
Summary:     Changed the leftovers check in check_sense_data to be for data loaded from the file to make the test more robust.

Affected #:  1 file

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 499bfa3..2dda375 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -190,14 +190,14 @@ void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std:
           CHECK_EQUAL( senses[i], known_senses[j] );
           //Once a wrt entity is matched with a known entity,
           // remove it from the list
-          known_wrt_ids.erase( known_wrt_ids.begin()+j );
-          known_senses.erase( known_senses.begin()+j );
+          wrt_ent_ids.erase( wrt_ent_ids.begin()+i );
+          senses.erase( senses.begin()+i );
          }
      }
   }
 
   // After both loops are complete, known_wrt_ents should be empty 
-  int leftovers = known_wrt_ids.size();
+  int leftovers = wrt_ent_ids.size();
   CHECK_EQUAL( leftovers, 0 );
 
 }


https://bitbucket.org/fathomteam/moab/commits/5956dcd3f9df/
Changeset:   5956dcd3f9df
Branch:      None
User:        pshriwise
Date:        2014-02-15 21:29:23
Summary:     Added .stp file load (if built with occ) to read_cgm_connectivity_test.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index f0e67c24..db370cc 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -20,10 +20,19 @@ using namespace moab;
 
 
 #ifdef MESHDIR
-static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
 #else
-static const char input_cube[] = "/io/cube.sat";
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
 #endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = "cylcube.stp";
+#else
+static const char input_cylcube[] = "cylcube.sat";
+#endif
+#endif
+
 
 // Function used to load the test file
 void read_file( Interface* moab, const char* input_file );
@@ -69,7 +78,7 @@ void cube_verts_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
 
   //Get all vertex handles from the mesh
   Range verts;
@@ -95,7 +104,7 @@ void cube_tris_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
 
   //Get triangles from the mesh
   Range tris;
@@ -130,7 +139,7 @@ void cube_tri_curve_coincidence_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
 
   //Get curves from the mesh
   Range curves;
@@ -184,7 +193,7 @@ void cube_edge_adjacencies_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
 
   //Get the curves 
   Range curves;
@@ -211,7 +220,7 @@ void cube_tri_vertex_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cube );
+  read_file( mb, input_cylcube );
  
   //Get all triangles
   Range tris;


https://bitbucket.org/fathomteam/moab/commits/bbc753a599f8/
Changeset:   bbc753a599f8
Branch:      None
User:        pshriwise
Date:        2014-02-16 19:57:01
Summary:     Altered the query initialization for groups in the ReadCGM group test function.

Affected #:  1 file

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 4148434..4bbc95a 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -92,7 +92,7 @@ void read_cylcube_groups_test()
 
   //Get the group entity handles
   Range group_sets;
-  char query[] = "Group\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0\0";   
+  char query[CATEGORY_TAG_SIZE] = "Group\0";   
   //Has to be this way because of the way tags are created
   void* val[] = {&query};
   rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &category_tag, val, 1, group_sets);


https://bitbucket.org/fathomteam/moab/commits/295167396061/
Changeset:   295167396061
Branch:      None
User:        pshriwise
Date:        2014-02-16 19:59:53
Summary:     Removed a test that is run twice in ReadCGM connectivity tests.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index db370cc..0ebd4fc 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -54,7 +54,6 @@ int main(int /* argc */, char** /* argv */)
   result += RUN_TEST(cube_verts_connectivity_test);
   result += RUN_TEST(cube_tris_connectivity_test);
   result += RUN_TEST(cube_tri_curve_coincidence_test);
-  result += RUN_TEST(cube_tri_curve_coincidence_test);
   result += RUN_TEST(cube_tri_vertex_test);
  
   return result;


https://bitbucket.org/fathomteam/moab/commits/9b9e4d82c0f6/
Changeset:   9b9e4d82c0f6
Branch:      None
User:        pshriwise
Date:        2014-02-16 21:10:17
Summary:     Made a correction to the filename for ReadCGM connectivity test.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 0ebd4fc..7c8d8a9 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -21,15 +21,15 @@ using namespace moab;
 
 #ifdef MESHDIR
 #ifdef HAVE_OCC_STEP
-static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.stp";
 #else
-static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
 #endif
 #else
 #ifdef HAVE_OCC_STEP
-static const char input_cylcube[] = "cylcube.stp";
+static const char input_cube[] = "cube.stp";
 #else
-static const char input_cylcube[] = "cylcube.sat";
+static const char input_cube[] = "cube.sat";
 #endif
 #endif
 
@@ -77,7 +77,7 @@ void cube_verts_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cylcube );
+  read_file( mb, input_cube );
 
   //Get all vertex handles from the mesh
   Range verts;
@@ -103,7 +103,7 @@ void cube_tris_connectivity_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cylcube );
+  read_file( mb, input_cube );
 
   //Get triangles from the mesh
   Range tris;
@@ -138,12 +138,13 @@ void cube_tri_curve_coincidence_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cylcube );
+  read_file( mb, input_cube );
 
   //Get curves from the mesh
   Range curves;
   rval = mb->get_entities_by_type( 0, MBEDGE, curves );
   CHECK_ERR(rval);
+  curves.print();
 
   //Get triangles from the mesh
   Range tris;
@@ -192,7 +193,7 @@ void cube_edge_adjacencies_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cylcube );
+  read_file( mb, input_cube );
 
   //Get the curves 
   Range curves;
@@ -219,7 +220,7 @@ void cube_tri_vertex_test()
   //Open the test file
   Core moab;
   Interface* mb = &moab;
-  read_file( mb, input_cylcube );
+  read_file( mb, input_cube );
  
   //Get all triangles
   Range tris;


https://bitbucket.org/fathomteam/moab/commits/2374b56cf00c/
Changeset:   2374b56cf00c
Branch:      None
User:        pshriwise
Date:        2014-02-17 21:27:23
Summary:     Removed comment of cgm_version.h. Now building with versions of CGM > 12.2

Affected #:  1 file

diff --git a/src/io/ReadCGM.cpp b/src/io/ReadCGM.cpp
index e854a2e..bb9eb9a 100644
--- a/src/io/ReadCGM.cpp
+++ b/src/io/ReadCGM.cpp
@@ -16,7 +16,7 @@
 #pragma warning(disable:4786)
 #endif
 
-//#include "cgm_version.h"
+#include "cgm_version.h"
 #include "GeometryQueryTool.hpp"
 #include "ModelQueryEngine.hpp"
 #include "RefEntityName.hpp"


https://bitbucket.org/fathomteam/moab/commits/7dc304821652/
Changeset:   7dc304821652
Branch:      None
User:        pshriwise
Date:        2014-02-17 21:29:00
Summary:     Merge branch 'add_cgm_tests_3'

Affected #:  8 files

diff --git a/MeshFiles/unittest/io/cylcube.sat b/MeshFiles/unittest/io/cylcube.sat
new file mode 100644
index 0000000..0b65976
--- /dev/null
+++ b/MeshFiles/unittest/io/cylcube.sat
@@ -0,0 +1,202 @@
+1900 0 2 0           
+10 Cubit 12.2 17 ACIS 19.0.2 Linux 24 Thu Feb  6 08:36:54 2014 
+1 9.9999999999999995e-07 1e-10 
+body $2 -1 -1 $-1 $3 $-1 $4 T 25 -5 -5 35 5 5 #
+body $5 -1 -1 $-1 $6 $-1 $-1 T -5 -5 -5 5 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $7 $-1 $0 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+lump $8 -1 -1 $-1 $-1 $9 $0 T 25 -5 -5 35 5 5 #
+transform $-1 -1 1 0 0 0 1 0 0 0 1 0 0 0 1 no_rotate no_reflect no_shear #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $10 $-1 $1 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+lump $11 -1 -1 $-1 $-1 $12 $1 T -5 -5 -5 5 5 5 #
+simple-snl-attrib $-1 -1 $-1 $2 $0 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $13 $-1 $3 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+shell $-1 -1 -1 $-1 $-1 $-1 $14 $-1 $3 T 25 -5 -5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $5 $1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $15 $-1 $6 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+shell $-1 -1 -1 $-1 $-1 $-1 $16 $-1 $6 T -5 -5 -5 5 5 5 #
+simple-snl-attrib $-1 -1 $17 $8 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+face $18 -1 -1 $-1 $19 $20 $9 $-1 $21 forward single T 25 -5 5 35 5 5 F #
+simple-snl-attrib $-1 -1 $22 $11 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+face $23 -1 -1 $-1 $24 $25 $12 $-1 $26 forward single T -5 -5 -5 5 5 5 F #
+simple-snl-attrib $-1 -1 $27 $13 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 2 @5 GROUP @7 Group 2 0 7 1 2 618932362 0 0 0 0 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $28 $-1 $14 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+face $29 -1 -1 $-1 $30 $31 $9 $-1 $32 reversed single T 25 -5 -5 35 5 -5 F #
+loop $-1 -1 -1 $-1 $-1 $33 $14 T 25 -5 5 35 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 0 5 0 0 1 1 0 0 forward_v I I I I #
+simple-snl-attrib $-1 -1 $34 $15 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 2 @5 GROUP @7 Group 3 0 7 1 3 885205176 0 0 0 0 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $35 $-1 $16 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+face $36 -1 -1 $-1 $37 $38 $12 $-1 $39 forward single T -5 -5 -5 5 5 -5 F #
+loop $-1 -1 -1 $-1 $40 $41 $16 T -5 -5 -5 5 5 -5 unknown #
+cone-surface $-1 -1 -1 $-1 0 0 0 0 0 1 5 0 0 1 I I 0 1 5 forward I I I I #
+simple-snl-attrib $-1 -1 $-1 $17 $3 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 7 @16 GRAPHICS_OPTIONS @14 geometry color @10 mesh color @19 geometry visibility @15 mesh visibility @11 render mode @11 transparent 0 6 4 4 1 1 0 0 #
+simple-snl-attrib $-1 -1 $42 $18 $14 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $43 $-1 $19 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+face $44 -1 -1 $-1 $45 $46 $9 $-1 $47 reversed single T 25 -5 -5 35 -5 5 F #
+loop $-1 -1 -1 $-1 $-1 $48 $19 T 25 -5 -5 35 5 -5 unknown #
+plane-surface $-1 -1 -1 $-1 30 0 -5 0 0 1 1 0 0 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $49 $50 $51 $52 forward $20 $-1 #
+simple-snl-attrib $-1 -1 $-1 $22 $6 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 7 @16 GRAPHICS_OPTIONS @14 geometry color @10 mesh color @19 geometry visibility @15 mesh visibility @11 render mode @11 transparent 0 6 5 5 1 1 0 0 #
+simple-snl-attrib $-1 -1 $53 $23 $16 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $54 $-1 $24 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+face $55 -1 -1 $-1 $-1 $56 $12 $-1 $57 forward single T -5 -5 5 5 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $58 $24 T -5 -5 -5 5 5 -5 unknown #
+plane-surface $-1 -1 -1 $-1 0 0 -5 0 0 -1 -1 0 0 forward_v I I I I #
+loop $-1 -1 -1 $-1 $-1 $59 $16 T -5 -5 5 5 5 5 unknown #
+coedge $-1 -1 -1 $-1 $41 $41 $58 $60 reversed $25 $-1 #
+simple-snl-attrib $-1 -1 $-1 $28 $14 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $61 $29 $19 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $62 $-1 $30 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+face $63 -1 -1 $-1 $64 $65 $9 $-1 $66 reversed single T 25 -5 -5 25 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $67 $30 T 25 -5 -5 35 -5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 -5 0 0 1 0 0 0 1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $68 $69 $70 $71 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $72 $33 $73 $74 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $33 $72 $75 $76 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $77 $78 $33 $52 reversed $79 $-1 #
+edge $80 -1 -1 $-1 $81 -5 $82 5 $51 $83 forward @7 unknown T 35 -5 5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $35 $16 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $84 $36 $24 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $85 $-1 $37 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+loop $-1 -1 -1 $-1 $-1 $86 $37 T -5 -5 5 5 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 0 0 5 0 0 1 1 0 0 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $58 $58 $41 $60 forward $38 $-1 #
+coedge $-1 -1 -1 $-1 $59 $59 $86 $87 reversed $40 $-1 #
+edge $88 -1 -1 $-1 $89 0 $89 6.2831853071795862 $58 $90 forward @7 unknown T -5 -5 -5 5 5 -5 #
+simple-snl-attrib $-1 -1 $-1 $43 $19 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $91 $44 $30 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $92 $-1 $45 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+face $93 -1 -1 $-1 $94 $95 $9 $-1 $96 reversed single T 25 5 -5 35 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $97 $45 T 25 -5 -5 25 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 25 0 0 1 0 0 0 0 -1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $98 $75 $99 $100 forward $46 $-1 #
+coedge $-1 -1 -1 $-1 $101 $48 $98 $102 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $48 $101 $103 $104 forward $31 $-1 #
+coedge $-1 -1 -1 $-1 $78 $77 $48 $71 reversed $79 $-1 #
+edge $105 -1 -1 $-1 $106 -5 $107 5 $70 $108 forward @7 unknown T 35 -5 -5 35 5 -5 #
+coedge $-1 -1 -1 $-1 $50 $49 $109 $110 forward $20 $-1 #
+coedge $-1 -1 -1 $-1 $111 $112 $49 $74 reversed $95 $-1 #
+edge $113 -1 -1 $-1 $82 -5 $114 5 $73 $115 forward @7 unknown T 25 5 5 35 5 5 #
+coedge $-1 -1 -1 $-1 $67 $116 $50 $76 reversed $46 $-1 #
+edge $117 -1 -1 $-1 $118 -5 $81 5 $75 $119 forward @7 unknown T 25 -5 5 35 -5 5 #
+coedge $-1 -1 -1 $-1 $70 $51 $116 $120 forward $79 $-1 #
+coedge $-1 -1 -1 $-1 $51 $70 $111 $121 reversed $79 $-1 #
+loop $-1 -1 -1 $-1 $-1 $77 $94 T 35 -5 -5 35 5 5 unknown #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $122 $-1 $52 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+vertex $123 -1 -1 $-1 $52 $124 #
+vertex $125 -1 -1 $-1 $52 $126 #
+straight-curve $-1 -1 -1 $-1 35 0 5 0 1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $54 $24 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $127 $55 $37 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+coedge $-1 -1 -1 $-1 $86 $86 $59 $87 forward $56 $-1 #
+edge $128 -1 -1 $-1 $129 0 $129 6.2831853071795862 $86 $130 forward @7 unknown T -5 -5 5 5 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $131 $-1 $60 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 13 #
+vertex $132 -1 -1 $-1 $60 $133 #
+ellipse-curve $-1 -1 -1 $-1 0 0 -5 0 0 -1 5 0 0 1 I I #
+simple-snl-attrib $-1 -1 $-1 $62 $30 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $134 $63 $45 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $135 $-1 $64 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+face $136 -1 -1 $-1 $-1 $79 $9 $-1 $137 reversed single T 35 -5 -5 35 5 5 F #
+loop $-1 -1 -1 $-1 $-1 $111 $64 T 25 5 -5 35 5 5 unknown #
+plane-surface $-1 -1 -1 $-1 30 5 0 0 -1 0 0 0 -1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $138 $109 $112 $139 forward $65 $-1 #
+coedge $-1 -1 -1 $-1 $116 $67 $68 $102 reversed $46 $-1 #
+coedge $-1 -1 -1 $-1 $109 $138 $67 $100 reversed $65 $-1 #
+edge $140 -1 -1 $-1 $118 -5 $141 5 $99 $142 forward @7 unknown T 25 -5 -5 25 -5 5 #
+coedge $-1 -1 -1 $-1 $69 $68 $138 $143 forward $31 $-1 #
+edge $144 -1 -1 $-1 $107 -5 $141 5 $98 $145 forward @7 unknown T 25 -5 -5 35 -5 -5 #
+coedge $-1 -1 -1 $-1 $112 $111 $69 $104 reversed $95 $-1 #
+edge $146 -1 -1 $-1 $147 -5 $106 5 $103 $148 forward @7 unknown T 25 5 -5 35 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $149 $-1 $71 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+vertex $150 -1 -1 $-1 $71 $151 #
+vertex $152 -1 -1 $-1 $120 $153 #
+straight-curve $-1 -1 -1 $-1 35 0 -5 0 -1 0 I I #
+coedge $-1 -1 -1 $-1 $97 $99 $72 $110 reversed $65 $-1 #
+edge $154 -1 -1 $-1 $114 -5 $118 5 $109 $155 forward @7 unknown T 25 -5 5 25 5 5 #
+coedge $-1 -1 -1 $-1 $103 $73 $78 $121 forward $95 $-1 #
+coedge $-1 -1 -1 $-1 $73 $103 $97 $139 reversed $95 $-1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $156 $-1 $74 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+vertex $157 -1 -1 $-1 $74 $158 #
+straight-curve $-1 -1 -1 $-1 30 5 5 -1 0 0 I I #
+coedge $-1 -1 -1 $-1 $75 $98 $77 $120 reversed $46 $-1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $159 $-1 $76 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+vertex $160 -1 -1 $-1 $110 $161 #
+straight-curve $-1 -1 -1 $-1 30 -5 5 1 0 0 I I #
+edge $162 -1 -1 $-1 $81 -5 $107 5 $77 $163 forward @7 unknown T 35 -5 -5 35 -5 5 #
+edge $164 -1 -1 $-1 $82 -5 $106 5 $78 $165 forward @7 unknown T 35 5 -5 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $80 $52 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $166 $-1 $81 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 1 #
+point $-1 -1 -1 $-1 35 -5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $167 $-1 $82 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 2 #
+point $-1 -1 -1 $-1 35 5 5 #
+simple-snl-attrib $-1 -1 $-1 $85 $37 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $168 $-1 $87 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 14 #
+vertex $169 -1 -1 $-1 $87 $170 #
+ellipse-curve $-1 -1 -1 $-1 0 0 5 0 0 1 5 0 0 1 I I #
+simple-snl-attrib $-1 -1 $-1 $88 $60 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 13 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $171 $-1 $89 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+point $-1 -1 -1 $-1 5 0 -5 #
+simple-snl-attrib $-1 -1 $-1 $92 $45 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $172 $93 $64 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $173 $-1 $94 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+plane-surface $-1 -1 -1 $-1 35 0 0 -1 0 0 0 0 1 forward_v I I I I #
+coedge $-1 -1 -1 $-1 $99 $97 $101 $143 reversed $65 $-1 #
+edge $174 -1 -1 $-1 $114 -5 $147 5 $112 $175 forward @7 unknown T 25 5 -5 25 5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $176 $-1 $100 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 9 #
+vertex $177 -1 -1 $-1 $143 $178 #
+straight-curve $-1 -1 -1 $-1 25 -5 0 0 0 -1 I I #
+edge $179 -1 -1 $-1 $141 -5 $147 5 $138 $180 forward @7 unknown T 25 -5 -5 25 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $181 $-1 $102 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+straight-curve $-1 -1 -1 $-1 30 -5 -5 -1 0 0 I I #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $182 $-1 $104 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+vertex $183 -1 -1 $-1 $104 $184 #
+straight-curve $-1 -1 -1 $-1 30 5 -5 1 0 0 I I #
+simple-snl-attrib $-1 -1 $-1 $105 $71 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $185 $-1 $106 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 5 #
+point $-1 -1 -1 $-1 35 5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $186 $-1 $107 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 6 #
+point $-1 -1 -1 $-1 35 -5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $187 $-1 $110 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+straight-curve $-1 -1 -1 $-1 25 0 5 0 -1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $113 $74 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $188 $-1 $114 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 3 #
+point $-1 -1 -1 $-1 25 5 5 #
+simple-snl-attrib $-1 -1 $-1 $117 $76 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $189 $-1 $118 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 4 #
+point $-1 -1 -1 $-1 25 -5 5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $190 $-1 $120 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 10 #
+straight-curve $-1 -1 -1 $-1 35 -5 0 0 0 -1 I I #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $191 $-1 $121 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 12 #
+straight-curve $-1 -1 -1 $-1 35 5 0 0 0 -1 I I #
+simple-snl-attrib $-1 -1 $-1 $123 $81 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 1 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $125 $82 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 2 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $128 $87 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 14 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $192 $-1 $129 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 10 #
+point $-1 -1 -1 $-1 5 0 5 #
+simple-snl-attrib $-1 -1 $-1 $132 $89 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $135 $64 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $193 $136 $94 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $194 $-1 $139 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 11 #
+straight-curve $-1 -1 -1 $-1 25 5 0 0 0 -1 I I #
+simple-snl-attrib $-1 -1 $-1 $140 $100 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 9 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $195 $-1 $141 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+point $-1 -1 -1 $-1 25 -5 -5 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $196 $-1 $143 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 7 #
+straight-curve $-1 -1 -1 $-1 25 0 -5 0 1 0 I I #
+simple-snl-attrib $-1 -1 $-1 $144 $102 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $146 $104 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+integer_attrib-name_attrib-gen-attrib $-1 -1 $197 $-1 $147 2 1 1 1 1 1 1 1 1 1 1 1 1 1 0 1 1 1 @8 CUBIT_ID 8 #
+point $-1 -1 -1 $-1 25 5 -5 #
+simple-snl-attrib $-1 -1 $-1 $150 $106 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 5 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $152 $107 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 6 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $154 $110 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $157 $114 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 3 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $160 $118 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 4 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $162 $120 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 10 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $164 $121 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 12 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $169 $129 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 10 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $173 $94 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 3 @13 MESH_INTERVAL @4 LIMP @4 LIMP 2 1 0 5 1 0 0 1 1 #
+simple-snl-attrib $-1 -1 $-1 $174 $139 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 11 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $177 $141 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $179 $143 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 7 -2147483648 -1 #
+simple-snl-attrib $-1 -1 $-1 $183 $147 1 1 1 1 1 1 1 1 1 1 1 1 0 1 0 1 1 1 @17 NEW_SIMPLE_ATTRIB 1 @9 ENTITY_ID 0 3 8 -2147483648 -1 #
+End-of-ACIS-data 
\ No newline at end of file

diff --git a/MeshFiles/unittest/io/cylcube.stp b/MeshFiles/unittest/io/cylcube.stp
new file mode 100644
index 0000000..bc4ec64
--- /dev/null
+++ b/MeshFiles/unittest/io/cylcube.stp
@@ -0,0 +1,290 @@
+ISO-10303-21;
+HEADER;
+FILE_DESCRIPTION(('STEP AP214'),'1');
+FILE_NAME('/home/user/cylcube.stp','2014-02-15T18:13:39',(' '),(' '),'Spatial InterOp 3D',' ',' ');
+FILE_SCHEMA(('automotive_design'));
+ENDSEC;
+DATA;
+#1=PRODUCT_DEFINITION_CONTEXT('',#13,'design');
+#2=APPLICATION_PROTOCOL_DEFINITION('INTERNATIONAL STANDARD','automotive_design',1994,#13);
+#3=PRODUCT_CATEGORY_RELATIONSHIP('NONE','NONE',#14,#15);
+#4=SHAPE_DEFINITION_REPRESENTATION(#16,#17);
+#5=PRODUCT_DEFINITION_CONTEXT('',#18,'design');
+#6=APPLICATION_PROTOCOL_DEFINITION('INTERNATIONAL STANDARD','automotive_design',1994,#18);
+#7=PRODUCT_CATEGORY_RELATIONSHIP('NONE','NONE',#19,#20);
+#8=SHAPE_DEFINITION_REPRESENTATION(#21,#22);
+#9= (GEOMETRIC_REPRESENTATION_CONTEXT(3)GLOBAL_UNCERTAINTY_ASSIGNED_CONTEXT((#25))GLOBAL_UNIT_ASSIGNED_CONTEXT((#27,#28,#29))REPRESENTATION_CONTEXT('NONE','WORKSPACE'));
+#13=APPLICATION_CONTEXT(' ');
+#14=PRODUCT_CATEGORY('part','NONE');
+#15=PRODUCT_RELATED_PRODUCT_CATEGORY('detail',' ',(#31));
+#16=PRODUCT_DEFINITION_SHAPE('NONE','NONE',#32);
+#17=ADVANCED_BREP_SHAPE_REPRESENTATION('1',(#33,#34),#9);
+#18=APPLICATION_CONTEXT(' ');
+#19=PRODUCT_CATEGORY('part','NONE');
+#20=PRODUCT_RELATED_PRODUCT_CATEGORY('detail',' ',(#35));
+#21=PRODUCT_DEFINITION_SHAPE('NONE','NONE',#36);
+#22=ADVANCED_BREP_SHAPE_REPRESENTATION('2',(#37,#38),#9);
+#25=UNCERTAINTY_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0E-06),#27,'','');
+#27= (CONVERSION_BASED_UNIT('MILLIMETRE',#41)LENGTH_UNIT()NAMED_UNIT(#44));
+#28= (NAMED_UNIT(#46)PLANE_ANGLE_UNIT()SI_UNIT($,.RADIAN.));
+#29= (NAMED_UNIT(#46)SOLID_ANGLE_UNIT()SI_UNIT($,.STERADIAN.));
+#31=PRODUCT('1','1','PART-1-DESC',(#52));
+#32=PRODUCT_DEFINITION('NONE','NONE',#53,#1);
+#33=MANIFOLD_SOLID_BREP('1',#54);
+#34=AXIS2_PLACEMENT_3D('',#55,#56,#57);
+#35=PRODUCT('2','2','PART-2-DESC',(#58));
+#36=PRODUCT_DEFINITION('NONE','NONE',#59,#5);
+#37=MANIFOLD_SOLID_BREP('2',#60);
+#38=AXIS2_PLACEMENT_3D('',#61,#62,#63);
+#41=LENGTH_MEASURE_WITH_UNIT(LENGTH_MEASURE(1.0),#64);
+#44=DIMENSIONAL_EXPONENTS(1.0,0.0,0.0,0.0,0.0,0.0,0.0);
+#46=DIMENSIONAL_EXPONENTS(0.0,0.0,0.0,0.0,0.0,0.0,0.0);
+#52=PRODUCT_CONTEXT('',#13,'mechanical');
+#53=PRODUCT_DEFINITION_FORMATION_WITH_SPECIFIED_SOURCE(' ','NONE',#31,.NOT_KNOWN.);
+#54=CLOSED_SHELL('',(#65,#66,#67,#68,#69,#70));
+#55=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#56=DIRECTION('',(0.0,0.0,1.0));
+#57=DIRECTION('',(1.0,0.0,0.0));
+#58=PRODUCT_CONTEXT('',#18,'mechanical');
+#59=PRODUCT_DEFINITION_FORMATION_WITH_SPECIFIED_SOURCE(' ','NONE',#35,.NOT_KNOWN.);
+#60=CLOSED_SHELL('',(#71,#72,#73,#74));
+#61=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#62=DIRECTION('',(0.0,0.0,1.0));
+#63=DIRECTION('',(1.0,0.0,0.0));
+#64= (NAMED_UNIT(#44)LENGTH_UNIT()SI_UNIT(.MILLI.,.METRE.));
+#65=ADVANCED_FACE('',(#76),#77,.T.);
+#66=ADVANCED_FACE('',(#78),#79,.F.);
+#67=ADVANCED_FACE('',(#80),#81,.F.);
+#68=ADVANCED_FACE('',(#82),#83,.F.);
+#69=ADVANCED_FACE('',(#84),#85,.F.);
+#70=ADVANCED_FACE('',(#86),#87,.F.);
+#71=ADVANCED_FACE('',(#88),#89,.T.);
+#72=ADVANCED_FACE('',(#90),#91,.T.);
+#73=ADVANCED_FACE('',(#92),#93,.T.);
+#74=ADVANCED_FACE('',(#94),#95,.T.);
+#76=FACE_OUTER_BOUND('',#96,.T.);
+#77=PLANE('',#97);
+#78=FACE_OUTER_BOUND('',#98,.T.);
+#79=PLANE('',#99);
+#80=FACE_OUTER_BOUND('',#100,.T.);
+#81=PLANE('',#101);
+#82=FACE_OUTER_BOUND('',#102,.T.);
+#83=PLANE('',#103);
+#84=FACE_OUTER_BOUND('',#104,.T.);
+#85=PLANE('',#105);
+#86=FACE_OUTER_BOUND('',#106,.T.);
+#87=PLANE('',#107);
+#88=FACE_OUTER_BOUND('',#108,.T.);
+#89=CYLINDRICAL_SURFACE('',#109,5.0);
+#90=FACE_OUTER_BOUND('',#110,.T.);
+#91=CYLINDRICAL_SURFACE('',#111,5.0);
+#92=FACE_OUTER_BOUND('',#112,.T.);
+#93=PLANE('',#113);
+#94=FACE_OUTER_BOUND('',#114,.T.);
+#95=PLANE('',#115);
+#96=EDGE_LOOP('',(#116,#117,#118,#119));
+#97=AXIS2_PLACEMENT_3D('',#120,#121,#122);
+#98=EDGE_LOOP('',(#123,#124,#125,#126));
+#99=AXIS2_PLACEMENT_3D('',#127,#128,#129);
+#100=EDGE_LOOP('',(#130,#131,#132,#133));
+#101=AXIS2_PLACEMENT_3D('',#134,#135,#136);
+#102=EDGE_LOOP('',(#137,#138,#139,#140));
+#103=AXIS2_PLACEMENT_3D('',#141,#142,#143);
+#104=EDGE_LOOP('',(#144,#145,#146,#147));
+#105=AXIS2_PLACEMENT_3D('',#148,#149,#150);
+#106=EDGE_LOOP('',(#151,#152,#153,#154));
+#107=AXIS2_PLACEMENT_3D('',#155,#156,#157);
+#108=EDGE_LOOP('',(#158,#159,#160,#161));
+#109=AXIS2_PLACEMENT_3D('',#162,#163,#164);
+#110=EDGE_LOOP('',(#165,#166,#167,#168));
+#111=AXIS2_PLACEMENT_3D('',#169,#170,#171);
+#112=EDGE_LOOP('',(#172,#173));
+#113=AXIS2_PLACEMENT_3D('',#174,#175,#176);
+#114=EDGE_LOOP('',(#177,#178));
+#115=AXIS2_PLACEMENT_3D('',#179,#180,#181);
+#116=ORIENTED_EDGE('',*,*,#182,.T.);
+#117=ORIENTED_EDGE('',*,*,#183,.T.);
+#118=ORIENTED_EDGE('',*,*,#184,.T.);
+#119=ORIENTED_EDGE('',*,*,#185,.T.);
+#120=CARTESIAN_POINT('',(30.0,0.0,5.0));
+#121=DIRECTION('',(0.0,0.0,1.0));
+#122=DIRECTION('',(1.0,0.0,0.0));
+#123=ORIENTED_EDGE('',*,*,#186,.T.);
+#124=ORIENTED_EDGE('',*,*,#187,.T.);
+#125=ORIENTED_EDGE('',*,*,#188,.T.);
+#126=ORIENTED_EDGE('',*,*,#189,.T.);
+#127=CARTESIAN_POINT('',(30.0,0.0,-5.0));
+#128=DIRECTION('',(0.0,0.0,1.0));
+#129=DIRECTION('',(1.0,0.0,0.0));
+#130=ORIENTED_EDGE('',*,*,#190,.T.);
+#131=ORIENTED_EDGE('',*,*,#187,.F.);
+#132=ORIENTED_EDGE('',*,*,#191,.F.);
+#133=ORIENTED_EDGE('',*,*,#185,.F.);
+#134=CARTESIAN_POINT('',(30.0,-5.0,0.0));
+#135=DIRECTION('',(0.0,1.0,0.0));
+#136=DIRECTION('',(0.0,0.0,1.0));
+#137=ORIENTED_EDGE('',*,*,#192,.T.);
+#138=ORIENTED_EDGE('',*,*,#188,.F.);
+#139=ORIENTED_EDGE('',*,*,#190,.F.);
+#140=ORIENTED_EDGE('',*,*,#184,.F.);
+#141=CARTESIAN_POINT('',(25.0,0.0,0.0));
+#142=DIRECTION('',(1.0,0.0,0.0));
+#143=DIRECTION('',(0.0,0.0,-1.0));
+#144=ORIENTED_EDGE('',*,*,#193,.T.);
+#145=ORIENTED_EDGE('',*,*,#189,.F.);
+#146=ORIENTED_EDGE('',*,*,#192,.F.);
+#147=ORIENTED_EDGE('',*,*,#183,.F.);
+#148=CARTESIAN_POINT('',(30.0,5.0,0.0));
+#149=DIRECTION('',(0.0,-1.0,0.0));
+#150=DIRECTION('',(0.0,0.0,-1.0));
+#151=ORIENTED_EDGE('',*,*,#191,.T.);
+#152=ORIENTED_EDGE('',*,*,#186,.F.);
+#153=ORIENTED_EDGE('',*,*,#193,.F.);
+#154=ORIENTED_EDGE('',*,*,#182,.F.);
+#155=CARTESIAN_POINT('',(35.0,0.0,0.0));
+#156=DIRECTION('',(-1.0,0.0,0.0));
+#157=DIRECTION('',(0.0,0.0,1.0));
+#158=ORIENTED_EDGE('',*,*,#194,.F.);
+#159=ORIENTED_EDGE('',*,*,#195,.F.);
+#160=ORIENTED_EDGE('',*,*,#196,.F.);
+#161=ORIENTED_EDGE('',*,*,#197,.F.);
+#162=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#163=DIRECTION('',(0.0,0.0,1.0));
+#164=DIRECTION('',(1.0,0.0,0.0));
+#165=ORIENTED_EDGE('',*,*,#194,.T.);
+#166=ORIENTED_EDGE('',*,*,#198,.F.);
+#167=ORIENTED_EDGE('',*,*,#196,.T.);
+#168=ORIENTED_EDGE('',*,*,#199,.F.);
+#169=CARTESIAN_POINT('',(0.0,0.0,0.0));
+#170=DIRECTION('',(0.0,0.0,1.0));
+#171=DIRECTION('',(1.0,0.0,0.0));
+#172=ORIENTED_EDGE('',*,*,#199,.T.);
+#173=ORIENTED_EDGE('',*,*,#195,.T.);
+#174=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#175=DIRECTION('',(0.0,0.0,-1.0));
+#176=DIRECTION('',(-1.0,0.0,0.0));
+#177=ORIENTED_EDGE('',*,*,#197,.T.);
+#178=ORIENTED_EDGE('',*,*,#198,.T.);
+#179=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#180=DIRECTION('',(0.0,0.0,1.0));
+#181=DIRECTION('',(1.0,0.0,0.0));
+#182=EDGE_CURVE('',#200,#201,#202,.T.);
+#183=EDGE_CURVE('',#201,#203,#204,.T.);
+#184=EDGE_CURVE('',#203,#205,#206,.T.);
+#185=EDGE_CURVE('',#205,#200,#207,.T.);
+#186=EDGE_CURVE('',#208,#209,#210,.T.);
+#187=EDGE_CURVE('',#209,#211,#212,.T.);
+#188=EDGE_CURVE('',#211,#213,#214,.T.);
+#189=EDGE_CURVE('',#213,#208,#215,.T.);
+#190=EDGE_CURVE('',#205,#211,#216,.T.);
+#191=EDGE_CURVE('',#200,#209,#217,.T.);
+#192=EDGE_CURVE('',#203,#213,#218,.T.);
+#193=EDGE_CURVE('',#201,#208,#219,.T.);
+#194=EDGE_CURVE('',#220,#221,#222,.T.);
+#195=EDGE_CURVE('',#223,#220,#224,.T.);
+#196=EDGE_CURVE('',#225,#223,#226,.T.);
+#197=EDGE_CURVE('',#221,#225,#227,.T.);
+#198=EDGE_CURVE('',#225,#221,#228,.T.);
+#199=EDGE_CURVE('',#220,#223,#229,.T.);
+#200=VERTEX_POINT('',#230);
+#201=VERTEX_POINT('',#231);
+#202=LINE('',#232,#233);
+#203=VERTEX_POINT('',#234);
+#204=LINE('',#235,#236);
+#205=VERTEX_POINT('',#237);
+#206=LINE('',#238,#239);
+#207=LINE('',#240,#241);
+#208=VERTEX_POINT('',#242);
+#209=VERTEX_POINT('',#243);
+#210=LINE('',#244,#245);
+#211=VERTEX_POINT('',#246);
+#212=LINE('',#247,#248);
+#213=VERTEX_POINT('',#249);
+#214=LINE('',#250,#251);
+#215=LINE('',#252,#253);
+#216=LINE('',#254,#255);
+#217=LINE('',#256,#257);
+#218=LINE('',#258,#259);
+#219=LINE('',#260,#261);
+#220=VERTEX_POINT('',#262);
+#221=VERTEX_POINT('',#263);
+#222=LINE('',#264,#265);
+#223=VERTEX_POINT('',#266);
+#224=CIRCLE('',#267,5.0);
+#225=VERTEX_POINT('',#268);
+#226=LINE('',#269,#270);
+#227=CIRCLE('',#271,5.0);
+#228=CIRCLE('',#272,5.0);
+#229=CIRCLE('',#273,5.0);
+#230=CARTESIAN_POINT('',(35.0,-5.0,5.0));
+#231=CARTESIAN_POINT('',(35.0,5.0,5.0));
+#232=CARTESIAN_POINT('',(35.0,0.0,5.0));
+#233=VECTOR('',#274,1.0);
+#234=CARTESIAN_POINT('',(25.0,5.0,5.0));
+#235=CARTESIAN_POINT('',(30.0,5.0,5.0));
+#236=VECTOR('',#275,1.0);
+#237=CARTESIAN_POINT('',(25.0,-5.0,5.0));
+#238=CARTESIAN_POINT('',(25.0,0.0,5.0));
+#239=VECTOR('',#276,1.0);
+#240=CARTESIAN_POINT('',(30.0,-5.0,5.0));
+#241=VECTOR('',#277,1.0);
+#242=CARTESIAN_POINT('',(35.0,5.0,-5.0));
+#243=CARTESIAN_POINT('',(35.0,-5.0,-5.0));
+#244=CARTESIAN_POINT('',(35.0,0.0,-5.0));
+#245=VECTOR('',#278,1.0);
+#246=CARTESIAN_POINT('',(25.0,-5.0,-5.0));
+#247=CARTESIAN_POINT('',(30.0,-5.0,-5.0));
+#248=VECTOR('',#279,1.0);
+#249=CARTESIAN_POINT('',(25.0,5.0,-5.0));
+#250=CARTESIAN_POINT('',(25.0,0.0,-5.0));
+#251=VECTOR('',#280,1.0);
+#252=CARTESIAN_POINT('',(30.0,5.0,-5.0));
+#253=VECTOR('',#281,1.0);
+#254=CARTESIAN_POINT('',(25.0,-5.0,0.0));
+#255=VECTOR('',#282,1.0);
+#256=CARTESIAN_POINT('',(35.0,-5.0,0.0));
+#257=VECTOR('',#283,1.0);
+#258=CARTESIAN_POINT('',(25.0,5.0,0.0));
+#259=VECTOR('',#284,1.0);
+#260=CARTESIAN_POINT('',(35.0,5.0,0.0));
+#261=VECTOR('',#285,1.0);
+#262=CARTESIAN_POINT('',(5.0,0.0,-5.0));
+#263=CARTESIAN_POINT('',(5.0,0.0,5.0));
+#264=CARTESIAN_POINT('',(5.0,-6.12303176911189E-16,0.0));
+#265=VECTOR('',#286,1.0);
+#266=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,-5.0));
+#267=AXIS2_PLACEMENT_3D('',#287,#288,#289);
+#268=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,5.0));
+#269=CARTESIAN_POINT('',(-5.0,6.12303176911189E-16,0.0));
+#270=VECTOR('',#290,1.0);
+#271=AXIS2_PLACEMENT_3D('',#291,#292,#293);
+#272=AXIS2_PLACEMENT_3D('',#294,#295,#296);
+#273=AXIS2_PLACEMENT_3D('',#297,#298,#299);
+#274=DIRECTION('',(0.0,1.0,0.0));
+#275=DIRECTION('',(-1.0,0.0,0.0));
+#276=DIRECTION('',(0.0,-1.0,0.0));
+#277=DIRECTION('',(1.0,0.0,0.0));
+#278=DIRECTION('',(0.0,-1.0,0.0));
+#279=DIRECTION('',(-1.0,0.0,0.0));
+#280=DIRECTION('',(0.0,1.0,0.0));
+#281=DIRECTION('',(1.0,0.0,0.0));
+#282=DIRECTION('',(0.0,0.0,-1.0));
+#283=DIRECTION('',(0.0,0.0,-1.0));
+#284=DIRECTION('',(0.0,0.0,-1.0));
+#285=DIRECTION('',(0.0,0.0,-1.0));
+#286=DIRECTION('',(0.0,0.0,1.0));
+#287=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#288=DIRECTION('',(0.0,0.0,-1.0));
+#289=DIRECTION('',(1.0,0.0,0.0));
+#290=DIRECTION('',(-0.0,-0.0,-1.0));
+#291=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#292=DIRECTION('',(0.0,0.0,1.0));
+#293=DIRECTION('',(1.0,0.0,0.0));
+#294=CARTESIAN_POINT('',(0.0,0.0,5.0));
+#295=DIRECTION('',(0.0,0.0,1.0));
+#296=DIRECTION('',(1.0,0.0,0.0));
+#297=CARTESIAN_POINT('',(0.0,0.0,-5.0));
+#298=DIRECTION('',(0.0,0.0,-1.0));
+#299=DIRECTION('',(1.0,0.0,0.0));
+ENDSEC;
+END-ISO-10303-21;

diff --git a/test/io/Makefile.am b/test/io/Makefile.am
index 6cf835a..61f932a 100644
--- a/test/io/Makefile.am
+++ b/test/io/Makefile.am
@@ -25,7 +25,8 @@ else
 endif
 
 if HAVE_CGM
-  CGM_TEST = read_cgm_load_test read_cgm_basic_test
+  CGM_TEST = read_cgm_load_test read_cgm_basic_test read_cgm_senses_test read_cgm_connectivity_test \
+             read_cgm_group_test
 else
   CGM_TEST = 
 endif
@@ -73,7 +74,13 @@ ccmio_test_SOURCES = $(srcdir)/../TestUtil.hpp ccmio_test.cpp
 read_cgm_load_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_load_test.cpp
 read_cgm_load_test_CXXFLAGS = $(CGM_CPPFLAGS)  $(CXXFLAGS)
 read_cgm_basic_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_basic_test.cpp
-read_cgm_basic_test_CXXFLAGS = $(CGM_CPPFLAGS)  $(CXXFLAGS)
+read_cgm_basic_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_senses_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_senses_test.cpp
+read_cgm_senses_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_connectivity_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_connectivity_test.cpp
+read_cgm_connectivity_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
+read_cgm_group_test_SOURCES = $(srcdir)/../TestUtil.hpp read_cgm_group_test.cpp
+read_cgm_group_test_CXXFLAGS = $(CGM_CPPFLAGS) $(CGM_LIBS)  $(CXXFLAGS)
 readutil_test_SOURCES = $(srcdir)/../TestUtil.hpp readutil_test.cpp
 cgns_test_SOURCES=$(srcdir)/../TestUtil.hpp cgns_test.cpp
 

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 7a2d07d..3a68d04 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -8,6 +8,8 @@
 #include "Internals.hpp"
 #include "moab/Core.hpp"
 #include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
 
 using namespace moab;
 
@@ -31,40 +33,295 @@ static const char input_cube[] = "cube.sat";
 #endif
 #endif
 
-void read_cube_test()
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// List of tests in this file
+void read_cube_verts_test();
+void read_cube_curves_test();
+void read_cube_tris_test();
+void read_cube_surfs_test();
+void read_cube_vols_test();
+void read_cube_vertex_pos_test();
+//void delete_mesh_test();
+
+
+int main(int /* argc */, char** /* argv */)
 {
-  Core mb;
+  int result = 0;
+ 
+  result += RUN_TEST(read_cube_verts_test);  
+  result += RUN_TEST(read_cube_curves_test);  
+  result += RUN_TEST(read_cube_tris_test);  
+  result += RUN_TEST(read_cube_surfs_test);  
+  result += RUN_TEST(read_cube_vols_test);  
+  result += RUN_TEST(read_cube_vertex_pos_test);  
  
-  ErrorCode rval = mb.load_file(input_cube); CHECK_ERR(rval);
+  return result;
+}
 
-  Tag geom_tag;
 
-  rval = mb.tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER,
-                                  geom_tag, MB_TAG_SPARSE|MB_TAG_CREAT); 
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
   CHECK_ERR(rval);
+}
+
+void read_cube_verts_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+   
+  int number_of_vertices;
+  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_vertices );
+  CHECK_ERR(rval);
+  //For a cube there should be exactly 8 vertices 
+  CHECK_EQUAL( 8, number_of_vertices );
+}
+
+
+void read_cube_tris_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
    
   int number_of_tris;
 
-  rval = mb.get_number_entities_by_type(0, MBTRI , number_of_tris);
+  rval = mb->get_number_entities_by_type( 0, MBTRI , number_of_tris );
   std::cout << "Number of Triangles = " << number_of_tris << std::endl;
   CHECK_ERR(rval);
+  //For a cube, there should be exactly 2 triangles per face
+  CHECK_EQUAL( 12, number_of_tris );  
+}
 
-  int number_of_vertices;
-  rval = mb.get_number_entities_by_type(0, MBVERTEX, number_of_vertices);
+void read_cube_curves_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+  //Get the geometry tag handle from the mesh   
+  Tag geom_tag;
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+				MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
   CHECK_ERR(rval);
+  //Get the curves from the mesh
+  int dim = 1;
+  void *val[] = {&dim};
+  int number_of_curves;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_curves );
+  CHECK_ERR(rval);
+  //For a cube, there should be exactly 12 curves loaded from the file
+  CHECK_EQUAL( 12, number_of_curves );  
 
+} 
 
-  if( number_of_tris != 12) rval = MB_FAILURE; CHECK_ERR(rval);
-   
-  if( number_of_vertices !=8) rval = MB_FAILURE; CHECK_ERR(rval);
+void read_cube_surfs_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+  
+  //Get geometry tag for pulling curve data from the mesh 
+  Tag geom_tag;
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  //Get the number of surface from the mesh geometry data
+  int dim = 2;
+  void *val[] = {&dim};
+  int number_of_surfs;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_surfs );
+  CHECK_ERR(rval);
+  //For a cube, there should be exactly 6 surfaces  
+  CHECK_EQUAL( 6, number_of_surfs );  
 
 }
+
+void read_cube_vols_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
   
-int main(int /* argc */, char** /* argv */)
+  //Get geometry tag for pulling curve data from the mesh 
+  Tag geom_tag;
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  //Get the number of volumes from the mesh geometry data
+  int dim = 3;
+  void *val[] = {&dim};
+  int number_of_vols;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_vols );
+  CHECK_ERR(rval);
+  CHECK_EQUAL( 1, number_of_vols );
+}
+
+void read_cube_vertex_pos_test()
 {
-  int result = 0;
   
-  result += RUN_TEST( read_cube_test );
-      
-  return result;
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //First check that the correct number of vertices are present
+  int number_of_verts;
+  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
+  CHECK_ERR(rval);
+
+  CHECK_EQUAL( 8, number_of_verts );
+
+  //Retrieve all vertex handles from the mesh
+  Range verts;
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
+  CHECK_ERR( rval );
+
+  //Get the vertex coordinates
+  double x[verts.size()];
+  double y[verts.size()];
+  double z[verts.size()];
+  rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
+  CHECK_ERR(rval);
+
+  //Check against known locations of the vertices
+
+  std::vector<double> x_ref;
+  std::vector<double> y_ref;
+  std::vector<double> z_ref;
+
+  // Vertex 1
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 2
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 3
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 4
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( 5 );
+
+  // Vertex 5
+  x_ref.push_back( 5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
+
+  // Vertex 6
+  x_ref.push_back( 5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
+
+  // Vertex 7
+  x_ref.push_back( -5 );
+  y_ref.push_back( -5 );
+  z_ref.push_back( -5 );
+ 
+  // Vertex 8
+  x_ref.push_back( -5 );
+  y_ref.push_back( 5 );
+  z_ref.push_back( -5 );
+ 
+  std::cout << verts.size() << std::endl;
+  std::cout << x_ref.size() << std::endl;
+  
+  for(unsigned int i=0; i<verts.size(); i++)
+    {
+      for(unsigned int j=0; j<x_ref.size(); j++)
+	{
+	  if( x[i]==x_ref[j] && y[i]==y_ref[j] && z[i]==z_ref[j] )
+            {
+              x_ref.erase( x_ref.begin()+j );
+              y_ref.erase( y_ref.begin()+j );
+              z_ref.erase( z_ref.begin()+j );
+            }
+	}
+    }
+  
+  //After looping through each vertex loaded from the mesh
+  //there should be no entities left in the reference vector
+  int leftovers = x_ref.size();
+  CHECK_EQUAL( 0, leftovers );
+
+}
+
+//Superfluous test for ReadCGM, but perhaps better 
+//than the test in place for moab::delete_geometry()
+
+
+/*
+void delete_mesh_test()
+{
+ Core moab;
+ Interface* mb = &moab;
+ read_file( mb, input_cube );
+
+ ErrorCode rval; 
+
+ //Get geometry tag for pulling curve data from the mesh
+ Tag geom_tag; 
+ rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                            geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+ CHECK_ERR(rval);
+
+ Range geom_sets[4];
+
+ for(unsigned dim=0; dim<4; dim++) 
+ {
+	void *val[] = {&dim};
+	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, geom_sets[dim] );
+        CHECK_ERR(rval); 
+
+        if( geom_sets[dim].size() == 0 ) std::cout << "Warning: No geom sets to begin with" << std::endl;
+
+ }
+
+ mb->delete_mesh();
+
+ Range geom_sets_after[4];
+ for(unsigned dim=0; dim<4; dim++) 
+ {
+	void *val_after[] = {&dim};
+	rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val_after, 1, geom_sets_after[dim] );
+        CHECK_ERR(rval); 
+
+        if( 0 != geom_sets_after[dim].size() ) rval = MB_FAILURE;
+
+        CHECK_ERR(rval);
+ }
+
 }
+ 
+*/

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
new file mode 100644
index 0000000..7c8d8a9
--- /dev/null
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -0,0 +1,244 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+#include "moab/MeshTopoUtil.hpp"
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+#ifdef HAVE_OCC_STEP
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.stp";
+#else
+static const char input_cube[] = STRINGIFY(MESHDIR) "/io/cube.sat";
+#endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cube[] = "cube.stp";
+#else
+static const char input_cube[] = "cube.sat";
+#endif
+#endif
+
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// List of tests in this file
+void cube_verts_connectivity_test();
+void cube_tris_connectivity_test();
+void cube_tri_curve_coincidence_test();
+void cube_edge_adjacencies_test();
+void cube_tri_vertex_test();
+
+//Other functions
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves );
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+ 
+  result += RUN_TEST(cube_verts_connectivity_test);
+  result += RUN_TEST(cube_tris_connectivity_test);
+  result += RUN_TEST(cube_tri_curve_coincidence_test);
+  result += RUN_TEST(cube_tri_vertex_test);
+ 
+  return result;
+}
+
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}
+
+void cube_verts_connectivity_test()
+{
+
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //Get all vertex handles from the mesh
+  Range verts;
+  rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
+  CHECK_ERR(rval);
+
+  //Check that each vertex connects to less than 4 triangles and no more than 6
+  for(Range::const_iterator i = verts.begin(); i!=verts.end(); i++)
+    {
+      std::vector<EntityHandle> adj_tris;
+      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris );
+      CHECK_ERR(rval);
+
+      int adj_size = adj_tris.size();
+      CHECK( adj_size >= 4 && adj_size <= 6 );
+    }
+    
+}
+
+void cube_tris_connectivity_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //Get triangles from the mesh
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
+  CHECK_ERR(rval);
+
+
+  for(Range::const_iterator i = tris.begin()+1; i!=tris.end(); i++)
+    {
+      Range adj_tris;
+      moab::MeshTopoUtil mu(mb);
+      //Use Triangle edges to get all adjacent triangles
+      rval = mu.get_bridge_adjacencies( *i, 1, 2, adj_tris );
+      CHECK_ERR(rval);
+      int number_of_adj_tris=adj_tris.size();      
+      CHECK_EQUAL( 3, number_of_adj_tris );
+      
+      //Check that the entities we found from bridge_adjacencies
+      //are triangles
+      Range adj_tri_test = adj_tris.subset_by_type( MBTRI );
+      int number_tris_in_adj_tris = adj_tri_test.size();
+      CHECK_EQUAL( number_of_adj_tris, number_tris_in_adj_tris );
+    
+    }
+
+}
+
+void cube_tri_curve_coincidence_test()
+{
+
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //Get curves from the mesh
+  Range curves;
+  rval = mb->get_entities_by_type( 0, MBEDGE, curves );
+  CHECK_ERR(rval);
+  curves.print();
+
+  //Get triangles from the mesh
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+    {
+      //Get the any curve edges that are a part of the triangle
+      Range tri_edges;
+      rval = mb->get_adjacencies( &(*i), 1, 1, false, tri_edges );
+      CHECK_ERR(rval);
+      //Check that we've retrieved two edges from get_adjacencies
+      //For a this file (cube), each triangle should have two curve
+      //edges
+      int num_of_tri_edges = tri_edges.size();
+      CHECK_EQUAL( 2, num_of_tri_edges );
+      rval = match_tri_edges_w_curve( mb, tri_edges, curves );
+      CHECK_ERR(rval);
+      }
+}
+
+ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
+{
+  ErrorCode rval;
+  int match_counter=0;
+  for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)
+    {
+      for(Range::const_iterator j=curves.begin(); j!=curves.end(); j++)
+	{
+          // If the edge handle matches a curve handle, increment the number
+          // matches
+          if( *i  == *j  ) match_counter++;
+	}
+    }
+  //Make sure that each edge returned from triangle edges
+  //has been matched to a curve
+  int num_of_tri_edges = tri_edges.size();
+  CHECK_EQUAL( num_of_tri_edges, match_counter );
+  return MB_SUCCESS;
+} 
+
+void cube_edge_adjacencies_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+
+  //Get the curves 
+  Range curves;
+  rval = mb->get_entities_by_type( 0, MBEDGE, curves );
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=curves.begin(); i!=curves.end(); i++)
+    {
+      //Get triangle adjacent to each edge
+      Range adj_tris;
+      rval = mb->get_adjacencies( &(*i), 1, 2, false, adj_tris );
+      CHECK_ERR(rval);
+      
+      int num_adj_tris = adj_tris.size();
+      //Ensure that no edge is adjacent to more than two triangles
+      CHECK( num_adj_tris <= 2 );
+    }
+
+}
+
+void cube_tri_vertex_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cube );
+ 
+  //Get all triangles
+  Range tris;
+  rval = mb->get_entities_by_type( 0, MBTRI, tris );
+  CHECK_ERR(rval);
+
+  for(Range::const_iterator i=tris.begin(); i!=tris.end(); i++)
+    {
+      //Get all triangle vertices
+      Range verts;
+      rval = mb->get_connectivity( &(*i), 1, verts );
+      CHECK_ERR(rval);
+      //Make sure that each vertex making up
+      //the triangle is different
+      int number_of_verts = verts.size();
+      CHECK( 3 == number_of_verts );
+      CHECK( verts[0]!=verts[1] );
+      CHECK( verts[1]!=verts[2] );      
+      CHECK( verts[2]!=verts[0] );
+    } 
+}

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
new file mode 100644
index 0000000..4bbc95a
--- /dev/null
+++ b/test/io/read_cgm_group_test.cpp
@@ -0,0 +1,203 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
+#else
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
+#endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = "cylcube.stp";
+#else
+static const char input_cylcube[] = "cylcube.sat";
+#endif
+#endif
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+//Function for getting entity ids
+int geom_id_by_handle( Interface* moab, const EntityHandle set );
+
+//Function for checking retrieved group data
+void check_group_data( std::vector<int> group_ids, std::vector<std::string> group_names, std::vector<int> group_ent_ids );
+
+//Function for loading all reference data
+void load_group_references( std::vector<int>& ids, std::vector<std::string>& names, std::vector<int>& ent_ids);
+
+// List of tests in this file
+void read_cylcube_groups_test();
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+
+  result+=RUN_TEST(read_cylcube_groups_test);
+ 
+  return result;
+}
+
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}
+
+void read_cylcube_groups_test()
+{
+
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cylcube);  
+
+  //Get (or create) the name and category tags
+  Tag name_tag, category_tag;
+
+  rval = mb->tag_get_handle( NAME_TAG_NAME, NAME_TAG_SIZE, MB_TYPE_OPAQUE,
+                             name_tag, moab::MB_TAG_SPARSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+
+  rval = mb->tag_get_handle( CATEGORY_TAG_NAME, CATEGORY_TAG_SIZE,
+                             MB_TYPE_OPAQUE, category_tag,
+                             moab::MB_TAG_SPARSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+
+  //Get the group entity handles
+  Range group_sets;
+  char query[CATEGORY_TAG_SIZE] = "Group\0";   
+  //Has to be this way because of the way tags are created
+  void* val[] = {&query};
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &category_tag, val, 1, group_sets);
+  CHECK_ERR(rval);
+  //Get group names and IDs
+  std::vector<int> g_ids;
+  std::vector<std::string> g_names;
+  std::vector<int> g_ent_ids;
+  int j = 0;
+  for(Range::iterator i=group_sets.begin(); i!=group_sets.end(); i++)
+    {
+      int group_id = geom_id_by_handle( mb, *i );
+      g_ids.push_back(group_id);
+      //Get the group name
+      char group_name[NAME_TAG_SIZE+1];
+      rval = mb->tag_get_data( name_tag, &(*i), 1, &group_name);
+      CHECK_ERR(rval);
+      //Store group name
+      std::string temp(group_name);
+      g_names.push_back(temp);
+      //Get all entities in the group
+      Range group_ents;
+      rval = mb->get_entities_by_type( *i, MBENTITYSET, group_ents, false );
+      CHECK_ERR(rval);
+      if( group_ents.size() != 1) CHECK(false);
+      int grp_ent_id = geom_id_by_handle( mb, group_ents[0] );
+      g_ent_ids.push_back(grp_ent_id);
+  
+    }
+  check_group_data( g_ids, g_names, g_ent_ids );
+}
+
+
+void check_group_data(std::vector<int> group_ids, std::vector<std::string> group_names, std::vector<int> group_ent_ids )
+{
+
+  // Step files do not contain group data, MOAB shouldn't return errors when trying to access
+  // this data but there shouldn't be any found.
+#ifdef HAVE_OCC_STEP
+  int num_g_ids = group_ids.size();
+  int num_g_names = group_names.size();
+
+  CHECK_EQUAL( 0, num_g_ids );
+  CHECK_EQUAL( 0, num_g_names );
+#else
+
+
+  //Initialize reference data
+  std::vector<int> group_ref_ids;
+  std::vector<std::string> group_ref_names;
+  std::vector<int> group_ref_ent_ids;
+  load_group_references( group_ref_ids, group_ref_names, group_ref_ent_ids );
+
+  // check that the correct number of entities were found
+  CHECK_EQUAL ( group_ref_ids.size(), group_ids.size() );
+  CHECK_EQUAL ( group_ref_names.size(), group_names.size() );  
+  CHECK_EQUAL ( group_ref_ent_ids.size(), group_ent_ids.size() );
+
+  //now make sure that each group has a matching group
+  for(unsigned int i=0 ; i<group_ids.size(); i++)
+    {
+      for(unsigned int j=0; j<group_ref_ids.size(); j++)
+	{
+          if( group_ids[i]==group_ref_ids[j]
+	      && group_names[i] ==  group_ref_names[j]
+              && group_ent_ids[i]==group_ref_ent_ids[j])
+	    {
+              group_ref_ids.erase(group_ref_ids.begin()+j);
+              group_ref_names.erase(group_ref_names.begin()+j);
+              group_ref_ent_ids.erase(group_ref_ent_ids.begin()+j);
+              continue;
+	    }
+	}
+    }
+
+  // Check sizes of reference vectors after matching
+  // (all should be zero)
+   int leftovers = group_ref_ids.size();
+  CHECK_EQUAL( 0, leftovers );
+  leftovers = group_ref_names.size();
+  CHECK_EQUAL( 0, leftovers );
+  leftovers = group_ref_ent_ids.size();
+  CHECK_EQUAL( 0, leftovers );
+#endif
+}
+
+void load_group_references( std::vector<int>& ids, std::vector<std::string>& names, std::vector<int>& ent_ids )
+{
+  //First set of group info
+  names.push_back("Group 3"); ids.push_back(3); ent_ids.push_back(2);
+  
+  //Second set of group info
+  names.push_back("Group 2"); ids.push_back(2); ent_ids.push_back(1);
+}
+
+int geom_id_by_handle( Interface* moab, const EntityHandle set )
+{  
+    ErrorCode rval;
+    //Get the id_tag handle
+    Tag id_tag;
+    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
+    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    //Load the ID for the EntHandle given to the function                  
+    int id;
+    rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
+    CHECK_ERR(rval);                        
+    return id;
+ }

diff --git a/test/io/read_cgm_load_test.cpp b/test/io/read_cgm_load_test.cpp
index 5377220..6791f50 100644
--- a/test/io/read_cgm_load_test.cpp
+++ b/test/io/read_cgm_load_test.cpp
@@ -33,16 +33,17 @@ void read_multiple_test()
 {
   Core mb;
 
-  ErrorCode rval = mb.load_file(input_file);
+  ErrorCode rval = mb.load_file( input_file );
   CHECK_ERR(rval);
   // second load
-  rval = mb.load_file(input_file);
+  rval = mb.load_file( input_file );
   CHECK_ERR(rval);
 
 }
   
 int main(int /* argc */, char** /* argv */)
 {
+  
   int result = RUN_TEST( read_multiple_test );
 
   return result;

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
new file mode 100644
index 0000000..2dda375
--- /dev/null
+++ b/test/io/read_cgm_senses_test.cpp
@@ -0,0 +1,576 @@
+
+#include <iostream>
+#include "moab/Interface.hpp"
+#ifndef IS_BUILDING_MB
+#define IS_BUILDING_MB
+#endif
+#include "TestUtil.hpp"
+#include "Internals.hpp"
+#include "moab/Core.hpp"
+#include "MBTagConventions.hpp"
+#include "moab/GeomTopoTool.hpp"
+#include "InitCGMA.hpp"
+#include "GeometryQueryTool.hpp"
+
+#define SENSE_FORWARD 1
+#define SENSE_REVERSE -1 
+#define SENSE_UNKNOWN 0
+using namespace moab;
+
+#define CHKERR(A) do { if (MB_SUCCESS != (A)) { \
+  std::cerr << "Failure (error code " << (A) << ") at " __FILE__ ":" \
+            << __LINE__ << std::endl; \
+  return A; } } while(false)
+
+
+#ifdef MESHDIR
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.stp";
+#else
+static const char input_cylcube[] = STRINGIFY(MESHDIR) "/io/cylcube.sat";
+#endif
+#else
+#ifdef HAVE_OCC_STEP
+static const char input_cylcube[] = "cylcube.stp";
+#else
+static const char input_cylcube[] = "cylcube.sat";
+#endif
+#endif
+
+
+// Function used to load the test file
+void read_file( Interface* moab, const char* input_file );
+
+// Functions containing known sense data
+ErrorCode load_sat_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+ErrorCode load_stp_curve_sense_data( Interface* moab, EntityHandle curve,  std::vector<int>& surf_ids_out, std::vector<int>& senses_out );
+ErrorCode load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+ErrorCode load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out );
+
+// Functions used to compare sense information found in 
+// the model to reference information
+void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses );
+
+//Function used to get id's from entity handles
+int geom_id_by_handle( Interface* moab, const EntityHandle set );
+
+// List of tests in this file
+void read_cylcube_curve_senses_test();
+void read_cylcube_surf_senses_test();
+void delete_mesh_test();
+
+
+int main(int /* argc */, char** /* argv */)
+{
+  int result = 0;
+
+  result += RUN_TEST(read_cylcube_curve_senses_test);  
+  result += RUN_TEST(read_cylcube_surf_senses_test);  
+ 
+  return result;
+}
+
+
+void read_file( Interface* moab, const char* input_file )
+{
+  InitCGMA::initialize_cgma();
+  GeometryQueryTool::instance()->delete_geometry();
+
+  ErrorCode rval = moab->load_file( input_file );
+  CHECK_ERR(rval);
+}
+
+void read_cylcube_curve_senses_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cylcube );
+  
+  //Get all curve handles
+  Tag geom_tag;
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1,
+			MB_TYPE_INTEGER, geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  // Check that the proper number of curves exist
+  int dim = 1;
+  void *val[] = {&dim};
+  int number_of_curves;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+    					          val, 1, number_of_curves );
+  CHECK_ERR(rval);
+  //Step format adds a surface on the barrel of the cylinder.
+  //This created 4 extra surfaces in comparison to the .sat format from Cubit. 
+  //(New surface breaks the barrel of the cylinder into two half-pipes)
+#ifdef HAVE_OCC_STEP
+  CHECK_EQUAL( 18, number_of_curves );
+#else
+  CHECK_EQUAL( 14, number_of_curves );
+#endif
+
+  //Get curve handles
+  Range curves;
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, curves );
+  CHECK_ERR(rval);
+
+  // Establish GeomTopoTool instance needed to get curve data 
+  moab::GeomTopoTool gt( mb, false );  
+  // Initialize vectors for sense checking
+  std::vector<EntityHandle> surfs;
+  std::vector<int> senses;  
+  std::vector<int> known_surf_ids;
+  std::vector<int> known_senses;
+
+for(unsigned int i = 0; i < curves.size() ; i++)
+  {
+
+   //Clean data from previous curve
+   surfs.clear();
+   senses.clear();
+   //Get sense info for the current curve
+   gt.get_senses( curves[i], surfs, senses );
+   CHECK_ERR(rval);
+
+   //Clear reference data from previous curve
+   known_surf_ids.clear();
+   known_senses.clear();
+   //Load known curve-sense ID data
+#ifdef HAVE_OCC_STEP
+   rval = load_stp_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   CHECK_ERR(rval);
+#else
+   rval = load_sat_curve_sense_data( mb, curves[i], known_surf_ids, known_senses );
+   CHECK_ERR(rval);
+#endif
+
+   //Check that each surf and sense has a match in the references
+   check_sense_data( mb, surfs, senses, known_surf_ids, known_senses);
+  }
+}
+
+
+int geom_id_by_handle( Interface* moab, const EntityHandle set )
+{
+    
+    ErrorCode rval;
+    //Get the id_tag handle
+    Tag id_tag;
+    rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
+    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    //Load the ID for the EntHandle given to the function                  
+    int id;
+    rval = moab->tag_get_data( id_tag, &set, 1, &id );                  
+    CHECK_ERR(rval);                        
+    return id;
+ }
+
+void check_sense_data( Interface* moab, std::vector<EntityHandle> wrt_ents, std::vector<int> senses, 
+                             std::vector<int> known_wrt_ids, std::vector<int> known_senses )
+{
+  
+  //Get ID's of the wrt entities
+  std::vector<int> wrt_ent_ids;
+  for(unsigned int i=0 ; i<wrt_ents.size() ; i++)
+  {
+      wrt_ent_ids.push_back( geom_id_by_handle( moab, wrt_ents[i] ) );
+  }
+
+  for(unsigned int i=0; i< wrt_ent_ids.size() ; i++)
+  {
+     for(unsigned int j=0; j< known_wrt_ids.size(); j++)
+     {
+       if( wrt_ent_ids[i] == known_wrt_ids [j] )
+         {
+          // Make sure the senses of the matching wrt entities
+          // are correct
+          CHECK_EQUAL( senses[i], known_senses[j] );
+          //Once a wrt entity is matched with a known entity,
+          // remove it from the list
+          wrt_ent_ids.erase( wrt_ent_ids.begin()+i );
+          senses.erase( senses.begin()+i );
+         }
+     }
+  }
+
+  // After both loops are complete, known_wrt_ents should be empty 
+  int leftovers = wrt_ent_ids.size();
+  CHECK_EQUAL( leftovers, 0 );
+
+}
+
+//Loads two vectors with reference curve and curve_sense data
+ErrorCode load_sat_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+{
+
+  int curve_id = geom_id_by_handle( moab, curve );
+  switch(curve_id)
+  {
+    case 1:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 2:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 3:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 4:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 5:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 6:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 7:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 8:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 9:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 10:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 11:
+          surf_ids_out.push_back(4); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 12:
+          surf_ids_out.push_back(5); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 13:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+
+    case 14:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(9);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    default:
+          return MB_FAILURE;
+
+  } 
+  return MB_SUCCESS;
+}
+
+//Loads two vectors with reference curve and curve_sense data
+ErrorCode load_stp_curve_sense_data( Interface* moab, EntityHandle curve, std::vector<int>& surf_ids_out, std::vector<int>& senses_out )
+{
+
+  int curve_id = geom_id_by_handle( moab, curve );
+  switch(curve_id)
+  {
+    case 1:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 2:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 3:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 4:
+          surf_ids_out.push_back(1); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 5:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 6:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(3);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 7:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 8:
+          surf_ids_out.push_back(2); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 9:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(4);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 10:
+          surf_ids_out.push_back(3); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 11:
+          surf_ids_out.push_back(4); surf_ids_out.push_back(5);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 12:
+          surf_ids_out.push_back(5); surf_ids_out.push_back(6);
+          senses_out.push_back(SENSE_FORWARD); senses_out.push_back(SENSE_REVERSE);
+          break;
+
+    case 13:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+
+    case 14:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(9);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 15:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(8);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 16:
+      surf_ids_out.push_back(7); surf_ids_out.push_back(10);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 17:
+      surf_ids_out.push_back(8); surf_ids_out.push_back(10);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    case 18:
+      surf_ids_out.push_back(8); surf_ids_out.push_back(9);
+      senses_out.push_back(SENSE_REVERSE); senses_out.push_back(SENSE_FORWARD);
+      break;
+    default:
+          return MB_FAILURE;
+
+  } 
+  return MB_SUCCESS;
+}
+
+///SURFACE SENSE CHECKING
+void read_cylcube_surf_senses_test()
+{
+  ErrorCode rval;
+  //Open the test file
+  Core moab;
+  Interface* mb = &moab;
+  read_file( mb, input_cylcube );
+  
+  //Get geometry tag for gathering surface information from the mesh
+  Tag geom_tag;
+  rval = mb->tag_get_handle( GEOM_DIMENSION_TAG_NAME, 1, MB_TYPE_INTEGER, 
+                             geom_tag, moab::MB_TAG_DENSE|moab::MB_TAG_CREAT );
+  CHECK_ERR(rval);
+  
+  // Check that the proper number of surfaces exist
+  int dim = 2;
+  void *val[] = {&dim};
+  int number_of_surfs;
+  rval = mb->get_number_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, number_of_surfs );
+  CHECK_ERR(rval);
+  //Step format adds a surface on barrel of the cylinder.
+  // (Breaks it into two half-pipes)
+#ifdef HAVE_OCC_STEP
+  CHECK_EQUAL( 10, number_of_surfs );
+#else
+  CHECK_EQUAL( 9, number_of_surfs );
+#endif
+  // Get surface handles
+  Range surfs;
+  rval = mb->get_entities_by_type_and_tag( 0, MBENTITYSET, &geom_tag,
+	  					    val, 1, surfs );
+  CHECK_ERR(rval);
+
+  // Establish GeomTopoTool instance needed to get surf data 
+  moab::GeomTopoTool gt( mb, false );  
+  std::vector<EntityHandle> vols;
+  std::vector<int> senses;  
+  std::vector<int> known_vol_ids;
+  std::vector<int> known_senses;
+
+for(unsigned int i = 0; i < surfs.size(); i++)
+  {
+   //Clean data from previous surface
+   vols.clear();
+   senses.clear();
+   // Get sense information for the current
+   // surface from the mesh
+   gt.get_senses( surfs[i], vols, senses );
+   CHECK_ERR(rval);
+   //Clear previous reverence data
+   known_vol_ids.clear();
+   known_senses.clear();
+   // Load known surface-volume data 
+   // for this surface and check that it's correct
+#ifdef HAVE_OCC_STEP
+   rval = load_stp_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   CHECK_ERR(rval);
+#else
+   rval = load_sat_surf_sense_data( mb, surfs[i], known_vol_ids, known_senses );
+   CHECK_ERR(rval);
+#endif
+   // Check sense information from the loaded mesh against 
+   // reference sense information
+   check_sense_data( mb, vols, senses, known_vol_ids, known_senses );
+
+  }
+
+}
+
+//Loads reference surface to volume sense data into the reference vectors
+ErrorCode load_sat_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+
+  int surf_id = geom_id_by_handle( moab, surf );
+  switch(surf_id)
+  {
+    case 1:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 2:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 3:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 4:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 5:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 6:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 7:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+  
+    case 8:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 9:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+    default:
+          return MB_FAILURE;
+
+   }
+  return MB_SUCCESS;
+}
+
+//Loads reference surface to volume sense data into the reference vectors
+ErrorCode load_stp_surf_sense_data( Interface* moab, EntityHandle surf, std::vector<int>& vol_ids_out, std::vector<int>& senses_out ){
+
+  int surf_id = geom_id_by_handle( moab, surf );
+  switch(surf_id)
+  {
+    case 1:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 2:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 3:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 4:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 5:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 6:
+          vol_ids_out.push_back(1);
+          senses_out.push_back(SENSE_FORWARD); 
+          break;
+
+    case 7:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+  
+    case 8:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 9:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+
+    case 10:
+          vol_ids_out.push_back(2);
+          senses_out.push_back(SENSE_FORWARD);
+          break;
+    default:
+      std::cout << "Failure to find surface sense reference data. Returning failure..." << std::endl;
+          return MB_FAILURE;
+   }
+  return MB_SUCCESS;
+}
+


https://bitbucket.org/fathomteam/moab/commits/705e69c616a7/
Changeset:   705e69c616a7
Branch:      None
User:        pshriwise
Date:        2014-02-18 00:14:36
Summary:     Correction to the error check in geom_id_by_handle in ReadCGM senses test and group tests.

Affected #:  2 files

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 4bbc95a..b1b70ec 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -194,7 +194,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
     //Get the id_tag handle
     Tag id_tag;
     rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
-    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    CHECK_ERR(rval);
     //Load the ID for the EntHandle given to the function                  
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 2dda375..37ca244 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -160,7 +160,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
     //Get the id_tag handle
     Tag id_tag;
     rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
-    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    CHECK_ERR(rval);
     //Load the ID for the EntHandle given to the function                  
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  


https://bitbucket.org/fathomteam/moab/commits/88028006dd42/
Changeset:   88028006dd42
Branch:      None
User:        pshriwise
Date:        2014-02-18 16:58:12
Summary:     Altered init of vectors for testing vertex positions in the readCGM basic tests.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 3a68d04..5b798f6 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -199,10 +199,12 @@ void read_cube_vertex_pos_test()
   rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
   CHECK_ERR( rval );
 
+  number_of_verts = verts.size();
+  CHECK_EQUAL( 8, number_of_verts );
   //Get the vertex coordinates
-  double x[verts.size()];
-  double y[verts.size()];
-  double z[verts.size()];
+  double x[8];
+  double y[8];
+  double z[8];
   rval = mb-> get_coords( verts, &x[0], &y[0], &z[0] );
   CHECK_ERR(rval);
 


https://bitbucket.org/fathomteam/moab/commits/c75b549704b9/
Changeset:   c75b549704b9
Branch:      None
User:        pshriwise
Date:        2014-02-18 17:00:29
Summary:     Merge branch 'master' of bitbucket.org:pshriwise/moab

Affected #:  2 files

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index 4bbc95a..b1b70ec 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -194,7 +194,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
     //Get the id_tag handle
     Tag id_tag;
     rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
-    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    CHECK_ERR(rval);
     //Load the ID for the EntHandle given to the function                  
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  

diff --git a/test/io/read_cgm_senses_test.cpp b/test/io/read_cgm_senses_test.cpp
index 2dda375..37ca244 100644
--- a/test/io/read_cgm_senses_test.cpp
+++ b/test/io/read_cgm_senses_test.cpp
@@ -160,7 +160,7 @@ int geom_id_by_handle( Interface* moab, const EntityHandle set )
     //Get the id_tag handle
     Tag id_tag;
     rval = moab->tag_get_handle( GLOBAL_ID_TAG_NAME, 1, MB_TYPE_INTEGER, id_tag, moab::MB_TAG_DENSE );
-    assert( MB_SUCCESS==result || MB_ALREADY_ALLOCATED==result ); 
+    CHECK_ERR(rval);
     //Load the ID for the EntHandle given to the function                  
     int id;
     rval = moab->tag_get_data( id_tag, &set, 1, &id );                  


https://bitbucket.org/fathomteam/moab/commits/2149df91047b/
Changeset:   2149df91047b
Branch:      None
User:        pshriwise
Date:        2014-02-18 17:54:15
Summary:     Removed ErrorCode return from match_tri_edges_with_curve in basic ReadCGM tests.

Return was removed because it really doesn't apply as no MOAB interface function is used and the CHECK_EQUAL function should return the necessary error if the test fails.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index 7c8d8a9..e2738a5 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -45,7 +45,7 @@ void cube_edge_adjacencies_test();
 void cube_tri_vertex_test();
 
 //Other functions
-ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves );
+void match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves );
 
 int main(int /* argc */, char** /* argv */)
 {
@@ -162,14 +162,13 @@ void cube_tri_curve_coincidence_test()
       //edges
       int num_of_tri_edges = tri_edges.size();
       CHECK_EQUAL( 2, num_of_tri_edges );
-      rval = match_tri_edges_w_curve( mb, tri_edges, curves );
+      match_tri_edges_w_curve( mb, tri_edges, curves );
       CHECK_ERR(rval);
       }
 }
 
-ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
+void match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
 {
-  ErrorCode rval;
   int match_counter=0;
   for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)
     {
@@ -184,7 +183,6 @@ ErrorCode match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curve
   //has been matched to a curve
   int num_of_tri_edges = tri_edges.size();
   CHECK_EQUAL( num_of_tri_edges, match_counter );
-  return MB_SUCCESS;
 } 
 
 void cube_edge_adjacencies_test()


https://bitbucket.org/fathomteam/moab/commits/fbfe5ec879b1/
Changeset:   fbfe5ec879b1
Branch:      None
User:        pshriwise
Date:        2014-02-18 18:01:07
Summary:     Removed unused variable from ReadCGM groups test.

Affected #:  1 file

diff --git a/test/io/read_cgm_group_test.cpp b/test/io/read_cgm_group_test.cpp
index b1b70ec..925c2ce 100644
--- a/test/io/read_cgm_group_test.cpp
+++ b/test/io/read_cgm_group_test.cpp
@@ -101,7 +101,7 @@ void read_cylcube_groups_test()
   std::vector<int> g_ids;
   std::vector<std::string> g_names;
   std::vector<int> g_ent_ids;
-  int j = 0;
+
   for(Range::iterator i=group_sets.begin(); i!=group_sets.end(); i++)
     {
       int group_id = geom_id_by_handle( mb, *i );


https://bitbucket.org/fathomteam/moab/commits/9b6abfa5e714/
Changeset:   9b6abfa5e714
Branch:      None
User:        pshriwise
Date:        2014-02-18 20:11:44
Summary:     Removed a redundant test condition in the ReadCGM basic test.

Affected #:  1 file

diff --git a/test/io/read_cgm_basic_test.cpp b/test/io/read_cgm_basic_test.cpp
index 5b798f6..1029c52 100644
--- a/test/io/read_cgm_basic_test.cpp
+++ b/test/io/read_cgm_basic_test.cpp
@@ -187,19 +187,12 @@ void read_cube_vertex_pos_test()
   Interface* mb = &moab;
   read_file( mb, input_cube );
 
-  //First check that the correct number of vertices are present
-  int number_of_verts;
-  rval = mb->get_number_entities_by_type( 0, MBVERTEX, number_of_verts );
-  CHECK_ERR(rval);
-
-  CHECK_EQUAL( 8, number_of_verts );
-
   //Retrieve all vertex handles from the mesh
   Range verts;
   rval = mb->get_entities_by_type( 0, MBVERTEX, verts );
   CHECK_ERR( rval );
 
-  number_of_verts = verts.size();
+  int number_of_verts = verts.size();
   CHECK_EQUAL( 8, number_of_verts );
   //Get the vertex coordinates
   double x[8];


https://bitbucket.org/fathomteam/moab/commits/d5fe5af8d3c1/
Changeset:   d5fe5af8d3c1
Branch:      None
User:        pshriwise
Date:        2014-02-18 20:12:25
Summary:     Removed the moab interface parameter from match_tri_edgs_with_curve function in ReadCGM connectivity tests.

Affected #:  1 file

diff --git a/test/io/read_cgm_connectivity_test.cpp b/test/io/read_cgm_connectivity_test.cpp
index e2738a5..168ea7b 100644
--- a/test/io/read_cgm_connectivity_test.cpp
+++ b/test/io/read_cgm_connectivity_test.cpp
@@ -45,7 +45,7 @@ void cube_edge_adjacencies_test();
 void cube_tri_vertex_test();
 
 //Other functions
-void match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves );
+void match_tri_edges_w_curve( Range tri_edges, Range curves );
 
 int main(int /* argc */, char** /* argv */)
 {
@@ -162,12 +162,12 @@ void cube_tri_curve_coincidence_test()
       //edges
       int num_of_tri_edges = tri_edges.size();
       CHECK_EQUAL( 2, num_of_tri_edges );
-      match_tri_edges_w_curve( mb, tri_edges, curves );
+      match_tri_edges_w_curve( tri_edges, curves );
       CHECK_ERR(rval);
       }
 }
 
-void match_tri_edges_w_curve( Interface* moab, Range tri_edges, Range curves )
+void match_tri_edges_w_curve( Range tri_edges, Range curves )
 {
   int match_counter=0;
   for(Range::const_iterator i=tri_edges.begin(); i!=tri_edges.end(); i++)


https://bitbucket.org/fathomteam/moab/commits/9f98cceae59f/
Changeset:   9f98cceae59f
Branch:      None
User:        pshriwise
Date:        2014-02-21 17:06:39
Summary:     Merge branch 'master' of bitbucket.org:fathomteam/moab

Affected #:  6 files

diff --git a/examples/CrystalRouterExample.cpp b/examples/CrystalRouterExample.cpp
index 200f012..83a1e7c 100644
--- a/examples/CrystalRouterExample.cpp
+++ b/examples/CrystalRouterExample.cpp
@@ -18,12 +18,14 @@
  *
  *  the example needs to be launched in parallel.
  *  Every proc will build a list of tuples, that will be send to a few procs;
+ *  In general, we will send to num_comms tasks, and about num_tuples to each task
+ *  We vary num_comms and num_tuples for processor
  *
- *  every proc will send 1 tuple, to proc rank + 1 and rank + rank*(size-1)+2 , with value
- *    10000 * send + 100* rank
+ *  we will send long ints of the form
+ *    100000 * send + 1000* rank +j, where j is the index of tuple
  *
- *  at the receive, we verify we received
- *    10000 * rank + 100 * from
+ *  after routing, we verify we received
+ *    100000 * rank + 1000 * from
  *
  *    For some reportrank we also print the tuples.
  *
@@ -35,13 +37,20 @@
 
 /** @example CrystalRouterExample.cpp \n
  * \brief generalized gather scatter using tuples \n
- * <b>To run</b>: mpiexec -np <n> CrystalRouterExample [reportrank] \n
+ * <b>To run</b>: mpiexec -np <n> CrystalRouterExample -r [reportrank] -t [num_tuples] -n [num_comms] \n
  *
  */
 //
 #include "moab/ProcConfig.hpp"
 #include "moab/TupleList.hpp"
+#include "moab/ProgOptions.hpp"
+#include <time.h>
 #include <iostream>
+#include <sstream>
+
+const char BRIEF_DESC[] =
+    "Example of gather scatter with tuple lists \n";
+std::ostringstream LONG_DESC;
 
 using namespace moab;
 using namespace std;
@@ -50,56 +59,94 @@ int main(int argc, char **argv)
 {
   MPI_Init(&argc, &argv);
 
-  int reportrank = 1;
-  if (argc>1)
-    reportrank = atoi(argv[1]);
   ProcConfig pc(MPI_COMM_WORLD);
   int size = pc.proc_size();
   int rank = pc.proc_rank();
 
-  if (reportrank==rank)
+  // start copy
+  LONG_DESC << "This program does a gather scatter with a list of tuples. \n"
+          " It tries to see how much communication costs in terms of time and memory. \n"
+          << "It starts with creating a list of tuples to be sent from each processor, \n to a list of other processors.\n" <<
+          "The number of tuples and how many tasks to communicate to are controlled by input parameters.\n" <<
+          "After communication, we verify locally if we received what we expected. \n";
+  ProgOptions opts(LONG_DESC.str(), BRIEF_DESC);
+
+  // how many procs communicate to current proc, on average (we will vary that too)
+  int num_comms = 2;
+  opts.addOpt<int>("num_comms,n",
+       "each task will send to about num_comms other tasks some tuples (default 2)", &num_comms);
+
+  int num_tuples = 4;
+  opts.addOpt<int>("num_tuples,t",
+        "each task will send to some task about num_tuples tuples (default 4)", &num_tuples);
+
+  int reportrank = size+1;
+  opts.addOpt<int>("reporting_rank,r",
+      "this rank will report the tuples sent and the tuples received; it could be higher than num_procs, then no reporting"
+      ,&reportrank);
+
+  opts.parseCommandLine(argc, argv);
+
+
+
+
+  if (rank==reportrank || (reportrank>=size && rank == 0))
   {
-    std::cout << " there are " << size << " procs in example\n";
+    std::cout << " There are " << size << " tasks in example.\n";
+    std::cout<< " We will send groups of " << num_tuples << " from each task towards " <<
+        num_comms << " other tasks.\n";
   }
-  // send some data from proc i to i+n/2, also to i +n/2+1 modulo n, wher en is num procs
+
+  // send some data from proc i to i+n/2, also to i +n/2+1 modulo n, where n is num procs
 
   gs_data::crystal_data *cd = pc.crystal_router();
 
-  TupleList tl;
+  long total_n_tuples = num_comms*num_tuples;
 
-  // at most 100 to send
+  // vary the number of tasks to send to, and the number of tuples to send
+  if (rank<size/2)
+    num_comms--;
+  else
+    num_comms++;
+
+  if (rank<size/3)
+    num_tuples*=2;
+  else if (rank>size-size/3)
+    num_tuples/=2;
+
+
+  TupleList tl;
+  // at most num_tuples* num_comms to send
   // we do a preallocate with this; some tuples on some processors might need more memory, to be able
-  // to grow locally; 100 is a very large number for this example, considering that each task sends only
-  // 2 tuples. Some tasks might receive more tuples though, and in the process, some might grow more than
+  // to grow locally; Some tasks might receive more tuples though, and in the process, some might grow more than
   // others. By doing these logP sends/receives, we do not grow local memory too much.
-  tl.initialize(1, 1, 0, 1, 100);
+  tl.initialize(1, 1, 0, 1, num_tuples*num_comms);
   tl.enableWriteAccess();
-  // form 2 tuples, send to rank+1 and rank+2 (mod size)
+  // form num_tuples*num_comms tuples, send to various ranks
   unsigned int n = tl.get_n();
-  int sendTo = rank+1;
-  sendTo = sendTo%size;
-  long intToSend = 100*rank + 10000*sendTo;
-  tl.vi_wr[n]= sendTo;
-  tl.vl_wr[n]= intToSend;
-  tl.vr_wr[n]= 100.*rank;
-  tl.inc_n();
-
-  n = tl.get_n();
-  sendTo = rank+(rank+1)*rank+2;// just some number relatively different from rank
-  sendTo = sendTo%size;
-  intToSend = 100*rank + 10000*sendTo;
-  tl.vi_wr[n]= sendTo;
-  tl.vl_wr[n]= intToSend;
-  tl.vr_wr[n]= 1000.*rank;
-  tl.inc_n();
-
-  if (reportrank==rank)
+  for (int i=0; i<num_comms; i++)
+  {
+    int sendTo = rank+i*size/2+1;// spread out the send to, for a stress-like test
+    sendTo = sendTo%size;//
+    long intToSend = 1000*rank + 100000*sendTo;
+    for (int j=0; j<num_tuples; j++)
+    {
+      n = tl.get_n();
+      tl.vi_wr[n]= sendTo;
+      tl.vl_wr[n]= intToSend+j;
+      tl.vr_wr[n]= 10000.*rank+j;
+      tl.inc_n();
+    }
+  }
+
+  if (rank==reportrank)
   {
     std::cout << "rank " << rank << "\n";
     tl.print(" before sending");
   }
 
-  // all communication happens here:
+  clock_t tt = clock();
+  // all communication happens here; no mpi calls for the user
   ErrorCode rval = cd->gs_transfer(1,tl,0);
 
   if (MB_SUCCESS!= rval)
@@ -107,23 +154,34 @@ int main(int argc, char **argv)
     std::cout << "error in tuple transfer\n";
   }
 
-  if (reportrank==rank)
+  double secs=0;
+  if (rank==reportrank || (reportrank>=size && rank == 0))
+  {
+    secs = (clock() - tt) / (double) CLOCKS_PER_SEC;
+  }
+  if (rank==reportrank)
   {
     std::cout << "rank " << rank << "\n";
     tl.print(" after transfer");
   }
   // check that all tuples received have the form 10000* rank + 100*from
   unsigned int received = tl.get_n();
-  for (int i=0; i<received; i++)
+  for (int i=0; i<(int)received; i++)
   {
     int from = tl.vi_rd[i];
     long valrec = tl.vl_rd[i];
-    int remainder = valrec -10000*rank -100*from;
-    if (remainder != 0 )
+    int remainder = valrec -100000*rank -1000*from;
+    if (remainder < 0 || remainder >= num_tuples*4)
       std::cout << " error: tuple " << i << " received at proc rank " << rank << " from proc " << from << " has value " <<
          valrec << " remainder " <<  remainder << "\n";
   }
 
+  if (rank==reportrank || (reportrank>=size && rank == 0))
+  {
+    std::cout << "communication of about "<<  total_n_tuples << " tuples/per proc took "
+        << secs  << " seconds" << std::endl;
+        tt = clock();
+  }
   MPI_Finalize();
 
   return 0;

diff --git a/examples/StructuredMeshSimple.cpp b/examples/StructuredMeshSimple.cpp
index bd21dd1..bc80ed8 100644
--- a/examples/StructuredMeshSimple.cpp
+++ b/examples/StructuredMeshSimple.cpp
@@ -17,7 +17,7 @@
  *      -# Get the coordinates of the vertices comprising that element
  *    -# Release the structured mesh interface and destroy the MOAB instance
  *
- * <b> To run: </b> ./structuredmesh [d [N] ] \n
+ * <b> To run: </b> ./StructuredMeshSimple [d [N] ] \n
  * (default values so can run w/ no user interaction)
  */
 

diff --git a/examples/structuredmesh.cpp b/examples/structuredmesh.cpp
index 5ad42fb..0214c3e 100644
--- a/examples/structuredmesh.cpp
+++ b/examples/structuredmesh.cpp
@@ -28,6 +28,7 @@ using namespace moab;
 
 int main(int argc, char **argv) 
 {
+  argv[0] = argv[argc - argc]; // To remove the warnings about unused parameters
   int I, J, K;
     // progoptions?
   std::cout << "Enter I, J, K... " << std::endl;

diff --git a/src/io/Tqdcfr.cpp b/src/io/Tqdcfr.cpp
index 2c0317b..76767ea 100644
--- a/src/io/Tqdcfr.cpp
+++ b/src/io/Tqdcfr.cpp
@@ -2321,6 +2321,8 @@ ErrorCode Tqdcfr::read_acis_records( const char* sat_filename )
       
         // get next occurrence of '#' (record terminator)
       ret = strchr(&(char_buf[buf_pos]), '#');
+      while (ret && ret+1-&char_buf[0] < bytes_left && *(ret+1) != '\n')
+        ret = strchr(ret+1, '#');
       if (NULL != ret) {
           // grab the string (inclusive of the record terminator and the line feed) and complete the record
         int num_chars = ret-&(char_buf[buf_pos])+2;
@@ -2460,7 +2462,10 @@ ErrorCode Tqdcfr::parse_acis_attribs(const unsigned int entity_rec_num,
     }
     else if (strncmp(records[current_attrib].att_string.c_str(), "UNIQUE_ID", 9) == 0) {
         // parse uid
-      num_read = sscanf(records[current_attrib].att_string.c_str(), "UNIQUE_ID 1 0 1 %d", &uid);
+      if (major >=14) // change of format for cubit 14:
+        num_read =sscanf(records[current_attrib].att_string.c_str(), "UNIQUE_ID 0 1 %d", &uid);
+      else
+        num_read = sscanf(records[current_attrib].att_string.c_str(), "UNIQUE_ID 1 0 1 %d", &uid);
       if (1 != num_read) return MB_FAILURE;
     }
     else if (strncmp(records[current_attrib].att_string.c_str(), "COMPOSITE_ATTRIB @9 UNIQUE_ID", 29) == 0) {

diff --git a/tools/mbcoupler/Coupler.cpp b/tools/mbcoupler/Coupler.cpp
index 29dbb3d..b496441 100644
--- a/tools/mbcoupler/Coupler.cpp
+++ b/tools/mbcoupler/Coupler.cpp
@@ -113,11 +113,22 @@ ErrorCode Coupler::initialize_tree()
   box.bMax.get(&allBoxes[6*my_rank+3]);
   
     // now communicate to get all boxes
-    // use "in place" option
   if (myPc) {
-    int mpi_err = MPI_Allgather(MPI_IN_PLACE, 0, MPI_DATATYPE_NULL,
+    int mpi_err;
+#if (MPI_VERSION >= 2)
+      // use "in place" option
+    mpi_err = MPI_Allgather(MPI_IN_PLACE, 0, MPI_DATATYPE_NULL,
                                 &allBoxes[0], 6, MPI_DOUBLE, 
                                 myPc->proc_config().proc_comm());
+#else
+    {
+      std::vector<double> allBoxes_tmp(6*myPc->proc_config().proc_size());
+      mpi_err = MPI_Allgather( &allBoxes[6*my_rank], 6, MPI_DOUBLE,
+                                   &allBoxes_tmp[0], 6, MPI_DOUBLE, 
+                                   myPc->proc_config().proc_comm());
+      allBoxes = allBoxes_tmp;
+    }
+#endif
     if (MPI_SUCCESS != mpi_err) return MB_FAILURE;
   }
 

diff --git a/tools/mbcslam/Intx2Mesh.cpp b/tools/mbcslam/Intx2Mesh.cpp
index 22fdc3f..9859d00 100644
--- a/tools/mbcslam/Intx2Mesh.cpp
+++ b/tools/mbcslam/Intx2Mesh.cpp
@@ -483,10 +483,21 @@ ErrorCode Intx2Mesh::build_processor_euler_boxes(EntityHandle euler_set, Range &
   }
 
    // now communicate to get all boxes
-   // use "in place" option
-  int mpi_err = MPI_Allgather(MPI_IN_PLACE, 0, MPI_DATATYPE_NULL,
-                               &allBoxes[0], 6, MPI_DOUBLE,
-                               parcomm->proc_config().proc_comm());
+  int mpi_err;
+#if (MPI_VERSION >= 2)
+    // use "in place" option
+  mpi_err = MPI_Allgather(MPI_IN_PLACE, 0, MPI_DATATYPE_NULL,
+                          &allBoxes[0], 6, MPI_DOUBLE, 
+                          parcomm->proc_config().proc_comm());
+#else
+  {
+    std::vector<double> allBoxes_tmp(6*parcomm->proc_config().proc_size());
+    mpi_err = MPI_Allgather( &allBoxes[6*my_rank], 6, MPI_DOUBLE,
+                             &allBoxes_tmp[0], 6, MPI_DOUBLE, 
+                             parcomm->proc_config().proc_comm());
+    allBoxes = allBoxes_tmp;
+  }
+#endif
   if (MPI_SUCCESS != mpi_err) return MB_FAILURE;
 
   // also process the max number of vertices per cell (4 for quads, but could be more for polygons)


https://bitbucket.org/fathomteam/moab/commits/d27ee0670e36/
Changeset:   d27ee0670e36
Branch:      None
User:        pshriwise
Date:        2014-02-23 16:56:54
Summary:     Merge branch 'master' of bitbucket.org:fathomteam/moab

Affected #:  6 files
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/5b13a70196ae/
Changeset:   5b13a70196ae
Branch:      None
User:        pshriwise
Date:        2014-02-27 20:36:11
Summary:     Update to the triangle connectivity test for ReadCGM.

Affected #:  1 file
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/7c8638d51f39/
Changeset:   7c8638d51f39
Branch:      None
User:        pshriwise
Date:        2014-02-27 20:48:23
Summary:     Correction to a test comment in ReadCGM connectivity tests.

Affected #:  1 file
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/727e66e2315e/
Changeset:   727e66e2315e
Branch:      None
User:        pshriwise
Date:        2014-02-27 20:57:21
Summary:     Added test descriptions in ReadCGM tests.

Affected #:  2 files
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/a5ec35fcdba1/
Changeset:   a5ec35fcdba1
Branch:      None
User:        pshriwise
Date:        2014-02-27 21:00:54
Summary:     Added test descriptions to ReadCGM connectivity tests.

Affected #:  1 file
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/c16ea020b9db/
Changeset:   c16ea020b9db
Branch:      None
User:        pshriwise
Date:        2014-02-27 21:09:15
Summary:     Added a check inside a ReadCGM connectivity function.

Affected #:  1 file
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/15e4dfcb4d02/
Changeset:   15e4dfcb4d02
Branch:      None
User:        pshriwise
Date:        2014-02-28 20:14:45
Summary:     Merge branch 'master' of bitbucket.org:fathomteam/moab

Affected #:  5 files
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/b1292a1f1b13/
Changeset:   b1292a1f1b13
Branch:      None
User:        pshriwise
Date:        2014-03-09 00:24:20
Summary:     Merge branch 'master' of bitbucket.org:fathomteam/moab

Affected #:  4 files
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/57078cd610e0/
Changeset:   57078cd610e0
Branch:      None
User:        pshriwise
Date:        2014-03-09 00:49:47
Summary:     Added comments to ReadCGM test files.

Affected #:  4 files
Diff not available.

https://bitbucket.org/fathomteam/moab/commits/d644d9ca688d/
Changeset:   d644d9ca688d
Branch:      master
User:        gonuke
Date:        2014-03-26 02:52:33
Summary:     Merge remote-tracking branch 'pshriwise/master'

This should merge PR#21, with a robust set of tests for ReadCGM.

Affected #:  8 files
Diff not available.

Repository URL: https://bitbucket.org/fathomteam/moab/

--

This is a commit notification from bitbucket.org. You are receiving
this because you have the service enabled, addressing the recipient of
this email.


More information about the moab-dev mailing list