| 29 | </root>)"; |
| 30 | |
| 31 | TEST(EntryUpdates, NoEntry) |
| 32 | { |
| 33 | BehaviorTreeFactory factory; |
| 34 | std::array<int, 2> counters{}; |
| 35 | RegisterTestTick(factory, "Test", counters); |
| 36 | |
| 37 | const std::string xml_text = R"( |
| 38 | <root BTCPP_format="4" > |
| 39 | <BehaviorTree ID="Main"> |
| 40 | <Sequence> |
| 41 | <SubTree ID="Check" _autoremap="true"/> |
| 42 | </Sequence> |
| 43 | </BehaviorTree> |
| 44 | </root>)"; |
| 45 | |
| 46 | factory.registerBehaviorTreeFromText(xml_text_check); |
| 47 | factory.registerBehaviorTreeFromText(xml_text); |
| 48 | auto tree = factory.createTree("Main"); |
| 49 | const auto status = tree.tickWhileRunning(); |
| 50 | ASSERT_EQ(status, NodeStatus::SUCCESS); |
| 51 | EXPECT_EQ(1, counters[0]); // fallback! |
| 52 | EXPECT_EQ(0, counters[1]); // skipped |
| 53 | } |
| 54 | |
| 55 | TEST(EntryUpdates, Initialized) |
| 56 | { |
nothing calls this directly
no test coverage detected