feat(domain-and-input-skeleton): step 1 — domain-validation

This commit is contained in:
KOKO\Mimi
2026-07-30 17:08:07 +09:00
parent 96f3f3230e
commit 5a5af9c64b
8 changed files with 1202 additions and 50 deletions
+7 -12
View File
@@ -1,10 +1,8 @@
#include <fesa/model/domain.hpp>
#include <fesa/model/domain_builder.hpp>
#include <span>
#include <type_traits>
#include <utility>
#include <vector>
#include <gtest/gtest.h>
namespace {
@@ -31,15 +29,12 @@ TEST(EntityOrigin, FindsHierarchicalNodeByCompositeOrigin) {
fesa::EntityOrigin{"BeamPart", "Beam-1", 101},
fesa::Vec3{1.0, 2.0, 3.0},
};
const fesa::Domain domain{
std::vector<fesa::Node>{node},
{},
{},
{},
{},
{},
fesa::StepDefinition{"Load", {}, {}},
};
fesa::DomainBuilder builder;
builder.add_node(node);
builder.set_step(fesa::StepDefinition{"Load", {}, {}});
auto result = std::move(builder).build();
ASSERT_TRUE(result.domain.has_value());
const fesa::Domain& domain = *result.domain;
const fesa::EntityOrigin lookup{"BeamPart", "Beam-1", 101};
const fesa::Node& found_by_origin = domain.node(lookup);