29 using std::chrono::high_resolution_clock;
32 auto initial_time = high_resolution_clock::now();
37 std::this_thread::sleep_for(std::chrono::milliseconds(1));
SyncActionTest(const std::string &name)
const std::string & name() const
Name of the instance, not the type.
virtual void halt() override
bool isHaltRequested() const
AsyncActionTest(const std::string &name, BT::Duration deadline_ms=std::chrono::milliseconds(100))
The AsyncActionNode uses a different thread, where the action will be executed.
virtual void halt() override
void setExpectedResult(NodeStatus res)
The SyncActionNode is an ActionNode that explicitly prevents the status RUNNING and doesn't require a...
std::atomic< int > tick_count_
void setTime(BT::Duration time)
BT::NodeStatus tick() override
Method to be implemented by the user.
NodeStatus expected_result_
std::atomic< NodeStatus > expected_result_
void setExpectedResult(NodeStatus res)
BT::NodeStatus tick() override
Method to be implemented by the user.
std::chrono::high_resolution_clock::duration Duration