Public Member Functions | Private Attributes | List of all members
prbt_hardware_support::CANOpenChainNodeMock Class Reference

#include <canopen_chain_node_mock.h>

Public Member Functions

 CANOpenChainNodeMock ()
 Advertise get_object and set_object services for CANOpen objects and call setDefaultActions(). More...
void expectAnything ()
 Set expectations on all mock methods, that can be fullfilled in any case. More...
 MOCK_METHOD2 (get_obj, bool(canopen_chain_node::GetObjectRequest &, canopen_chain_node::GetObjectResponse &))
 MOCK_METHOD2 (set_obj, bool(canopen_chain_node::SetObjectRequest &, canopen_chain_node::SetObjectResponse &))
void setDefaultActions ()
 Set default actions on all expected service calls. More...
void shutdown ()
 Un-advertise services. More...
void shutdownGetService ()
 Un-advertise the get service. More...
void shutdownSetService ()
 Un-advertise the set service. More...

Private Attributes

ros::ServiceServer get_obj_serv_
ros::NodeHandle nh_
ros::ServiceServer set_obj_serv_

Detailed Description

Definition at line 30 of file canopen_chain_node_mock.h.

Constructor & Destructor Documentation

◆ CANOpenChainNodeMock()

prbt_hardware_support::CANOpenChainNodeMock::CANOpenChainNodeMock ( )

Advertise get_object and set_object services for CANOpen objects and call setDefaultActions().

Definition at line 38 of file canopen_chain_node_mock.cpp.

Member Function Documentation

◆ expectAnything()

void prbt_hardware_support::CANOpenChainNodeMock::expectAnything ( )

Set expectations on all mock methods, that can be fullfilled in any case.

Allows any number of calls on get_obj() and set_obj.

Definition at line 78 of file canopen_chain_node_mock.cpp.

◆ MOCK_METHOD2() [1/2]

prbt_hardware_support::CANOpenChainNodeMock::MOCK_METHOD2 ( get_obj  ,
bool(canopen_chain_node::GetObjectRequest &, canopen_chain_node::GetObjectResponse &)   

◆ MOCK_METHOD2() [2/2]

prbt_hardware_support::CANOpenChainNodeMock::MOCK_METHOD2 ( set_obj  ,
bool(canopen_chain_node::SetObjectRequest &, canopen_chain_node::SetObjectResponse &)   

◆ setDefaultActions()

void prbt_hardware_support::CANOpenChainNodeMock::setDefaultActions ( )

Set default actions on all expected service calls.

Does not set any expectations.

Definition at line 46 of file canopen_chain_node_mock.cpp.

◆ shutdown()

void prbt_hardware_support::CANOpenChainNodeMock::shutdown ( )

Un-advertise services.

Definition at line 93 of file canopen_chain_node_mock.cpp.

◆ shutdownGetService()

void prbt_hardware_support::CANOpenChainNodeMock::shutdownGetService ( )

Un-advertise the get service.

Definition at line 99 of file canopen_chain_node_mock.cpp.

◆ shutdownSetService()

void prbt_hardware_support::CANOpenChainNodeMock::shutdownSetService ( )

Un-advertise the set service.

Definition at line 104 of file canopen_chain_node_mock.cpp.

Member Data Documentation

◆ get_obj_serv_

ros::ServiceServer prbt_hardware_support::CANOpenChainNodeMock::get_obj_serv_

Definition at line 73 of file canopen_chain_node_mock.h.

◆ nh_

ros::NodeHandle prbt_hardware_support::CANOpenChainNodeMock::nh_

Definition at line 72 of file canopen_chain_node_mock.h.

◆ set_obj_serv_

ros::ServiceServer prbt_hardware_support::CANOpenChainNodeMock::set_obj_serv_

Definition at line 74 of file canopen_chain_node_mock.h.

The documentation for this class was generated from the following files:

autogenerated on Wed Nov 25 2020 03:10:38