| 489 | } |
| 490 | |
| 491 | void add_internal_line_relations( const geode::Section& model, |
| 492 | geode::SectionBuilder& builder, |
| 493 | absl::Span< const geode::uuid > line_uuids, |
| 494 | absl::Span< const geode::uuid > surface_uuids ) |
| 495 | { |
| 496 | builder.add_line_surface_internal_relationship( |
| 497 | model.line( line_uuids[3] ), model.surface( surface_uuids[0] ) ); |
| 498 | builder.add_line_surface_internal_relationship( |
| 499 | model.line( line_uuids[4] ), model.surface( surface_uuids[0] ) ); |
| 500 | builder.add_line_surface_internal_relationship( |
| 501 | model.line( line_uuids[5] ), model.surface( surface_uuids[0] ) ); |
| 502 | builder.add_line_surface_internal_relationship( |
| 503 | model.line( line_uuids[0] ), model.surface( surface_uuids[1] ) ); |
| 504 | builder.add_line_surface_internal_relationship( |
| 505 | model.line( line_uuids[1] ), model.surface( surface_uuids[1] ) ); |
| 506 | |
| 507 | for( const auto& line_id : geode::LRange{ 0, 1 } ) |
| 508 | { |
| 509 | for( const auto& embedding : |
| 510 | model.embedding_surfaces( model.line( line_uuids[line_id] ) ) ) |
| 511 | { |
| 512 | geode::OpenGeodeModelException::test( |
| 513 | embedding.id() == surface_uuids[1], |
| 514 | "Lines embeddings are wrong" ); |
| 515 | } |
| 516 | geode::OpenGeodeModelException::test( |
| 517 | model.nb_embeddings( line_uuids[line_id] ) == 1, |
| 518 | "All Lines should be embedded to 1 Surface" ); |
| 519 | geode::OpenGeodeModelException::test( |
| 520 | model.nb_embedding_surfaces( model.line( line_uuids[line_id] ) ) |
| 521 | == 1, |
| 522 | "All Lines should be embedded to 1 Surface" ); |
| 523 | } |
| 524 | geode::OpenGeodeModelException::test( |
| 525 | model.nb_internal_lines( model.surface( surface_uuids[0] ) ) == 3, |
| 526 | "Surface should embed 3 Lines" ); |
| 527 | geode::OpenGeodeModelException::test( |
| 528 | model.nb_internal_lines( model.surface( surface_uuids[1] ) ) == 2, |
| 529 | "Surface should embed 2 Lines" ); |
| 530 | } |
| 531 | |
| 532 | void test_boundary_ranges( const geode::Section& model, |
| 533 | absl::Span< const geode::uuid > corner_uuids, |
no test coverage detected