| 122 | } |
| 123 | |
| 124 | void test_clone( const geode::PointSet3D& point_set ) |
| 125 | { |
| 126 | const auto point_set2 = point_set.clone(); |
| 127 | geode::OpenGeodeMeshException::test( |
| 128 | point_set2->nb_vertices() == 3, "PointSet2 should have 3 vertices" ); |
| 129 | |
| 130 | const auto attribute = |
| 131 | point_set2->vertex_attribute_manager().find_attribute< bool >( "test" ); |
| 132 | geode::OpenGeodeMeshException::test( attribute->value( 0 ) == true, |
| 133 | "PointSet2 attribute value should be true" ); |
| 134 | |
| 135 | const geode::Point3D answer{ { 2.1, 9.4, 6.7 } }; |
| 136 | geode::OpenGeodeMeshException::test( point_set2->point( 2 ) == answer, |
| 137 | "PointSet2 vertex coordinates are not correct" ); |
| 138 | } |
| 139 | |
| 140 | void test() |
| 141 | { |