fixed some repository-related tests

This commit is contained in:
Sascha Kühl
2025-10-01 15:39:58 +02:00
parent 5d2d6d4a30
commit 12905e3df3
10 changed files with 45 additions and 15 deletions
+5
View File
@@ -49,6 +49,9 @@ public:
} else if (!has_node(name)) {
it->second->update_name(name);
nodes_by_name_[name] = it->second;
if (const auto i = nodes_by_name_.find(""); i != nodes_by_name_.end()) {
nodes_by_name_.erase(i);
}
relation_completer<Type>::complete(it->second);
log_.info("attach: update node name to '%s' (type: %s)", it->second->name().c_str(), it->second->type_index().name());
} else {
@@ -135,6 +138,8 @@ public:
return utils::ok(result.value()->info<Type>());
}
[[nodiscard]] utils::result<basic_object_info_ref, utils::error> basic_info(const std::string &name) const;
template<typename Type>
[[nodiscard]] utils::result<basic_object_info_ref, utils::error> basic_info() const {
auto result = find_node(std::type_index(typeid(Type)));