| 39 | #include <geode/tests/common.hpp> |
| 40 | |
| 41 | void test_create_vertices( |
| 42 | const geode::PointSet3D& point_set, geode::PointSetBuilder3D& builder ) |
| 43 | { |
| 44 | builder.create_point( geode::Point3D{ { 0.1, 0.2, 0.3 } } ); |
| 45 | builder.create_point( geode::Point3D{ { 2.1, 9.4, 6.7 } } ); |
| 46 | geode::OpenGeodeMeshException::test( |
| 47 | point_set.nb_vertices() == 2, "PointSet should have 2 vertices" ); |
| 48 | builder.create_vertices( 2 ); |
| 49 | geode::OpenGeodeMeshException::test( |
| 50 | point_set.nb_vertices() == 4, "PointSet should have 4 vertices" ); |
| 51 | geode::OpenGeodeMeshException::test( |
| 52 | point_set.point( 2 ) == geode::Point3D(), |
| 53 | "Default coordinates are not correct" ); |
| 54 | builder.set_point( 2, geode::Point3D{ { 2.3, 5.0, -1.2 } } ); |
| 55 | geode::OpenGeodeMeshException::test( |
| 56 | point_set.point( 2 ) == geode::Point3D( { 2.3, 5.0, -1.2 } ), |
| 57 | "Point coordinates have not been correctly set" ); |
| 58 | } |
| 59 | |
| 60 | void test_permutation( |
| 61 | const geode::PointSet3D& point_set, geode::PointSetBuilder3D& builder ) |
no test coverage detected