ifw-fcf 8.0.2
 
Loading...
Searching...
No Matches
testLampLcsIf.cpp File Reference
#include <ifw/fcf/devmgr/common/actionMgr.hpp>
#include <ifw/fcf/devmgr/common/config.hpp>
#include <ifw/fcf/devmgr/common/dataContext.hpp>
#include <ifw/fcf/devmgr/common/deviceFacade.hpp>
#include <ifw/fcf/devmgr/common/device.hpp>
#include <ifw/fcf/devmgr/common/deviceConfig.hpp>
#include <ifw/fcf/devmgr/common/deviceLcsIf.hpp>
#include "ifw/fcf/devmgr/devices/lampConfig.hpp"
#include "ifw/fcf/devmgr/devices/lampLcsIf.hpp"
#include <rad/dbAdapterRedis.hpp>
#include <rad/msgReplier.hpp>
#include <rad/smAdapter.hpp>
#include <boost/asio.hpp>
#include <gtest/gtest.h>
#include "mock/mockICommAdapter.hpp"
#include "mock/mockHelpers.hpp"

Classes

class  testLampLcsIf::TestLampConfig
 The TestLampConfig class. More...
 
class  testLampLcsIf::TestLampLcsIf
 

Namespaces

namespace  testLampLcsIf
 

Functions

void testLampLcsIf::ExpectReadHelper (std::shared_ptr< MockICommAdapter > comm_if, std::shared_ptr< testLampLcsIf::TestLampConfig > &, int, int)
 
void testLampLcsIf::FeedStat (ifw::fnd::defs::SubscriptionHandler &handler, std::shared_ptr< testLampLcsIf::TestLampConfig > &dev_cfg, const std::string &stat_node, int value)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, Ctor)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, Config)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, Connect)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, SwitchOn)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, SwitchOff)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsReady)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsOperational)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsTurningOn)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsTurningOff)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsOn)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsOff)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, IsHwFailure)
 
 testLampLcsIf::TEST_F (TestLampLcsIf, DISABLED_ReadStatus)
 
ifw::fnd::defs::CallResult MakeRpcReply (short code, ifw::fnd::defs::Status batch_status=ifw::fnd::defs::Status::Ok)
 Build a CallResult that carries a single short reply code, matching the convention every FCF RPC uses (RPC reply in output_arguments[0].data.value as short).
 
ifw::fnd::defs::Result MakeOk ()
 Build a generic "Ok" Result.
 

Variables

std::string const testLampLcsIf::CONFIG_CFG = std::string("config/config.yaml")
 
std::string const testLampLcsIf::LAMP_CFG = std::string("config/testLamp.yaml")
 
std::string const testLampLcsIf::LAMP_MAP_CFG = std::string("config/testMapLamp.yaml")
 
const short testLampLcsIf::STATE_NOT_OPERATIONAL = ifw::fcf::devmgr::common::STATE_NOT_OPERATIONAL
 
const short testLampLcsIf::STATE_OPERATIONAL = ifw::fcf::devmgr::common::STATE_OPERATIONAL
 
const short testLampLcsIf::SUBSTATE_NOTREADY = ifw::fcf::devmgr::common::SUBSTATE_NOTREADY
 
const short testLampLcsIf::SUBSTATE_INITIALISING = ifw::fcf::devmgr::common::SUBSTATE_INITIALISING
 
const short testLampLcsIf::SUBSTATE_READY_OFF = ifw::fcf::devmgr::actuator::SUBSTATE_READY_OFF
 
const short testLampLcsIf::SUBSTATE_READY_ON = ifw::fcf::devmgr::actuator::SUBSTATE_READY_ON
 
const short testLampLcsIf::SUBSTATE_ERROR = ifw::fcf::devmgr::common::SUBSTATE_ERROR
 
const short testLampLcsIf::SUBSTATE_OP_DISABLING = ifw::fcf::devmgr::common::SUBSTATE_OP_DISABLING
 
const short testLampLcsIf::SUBSTATE_OP_OFF = ifw::fcf::devmgr::actuator::SUBSTATE_OP_OFF
 
const short testLampLcsIf::SUBSTATE_OP_SWITCHING_OFF = ifw::fcf::devmgr::actuator::SUBSTATE_OP_SWITCHING_OFF
 
const short testLampLcsIf::SUBSTATE_OP_COOLING = ifw::fcf::devmgr::lamp::SUBSTATE_OP_COOLING
 
const short testLampLcsIf::SUBSTATE_OP_ON = ifw::fcf::devmgr::actuator::SUBSTATE_OP_ON
 
const short testLampLcsIf::SUBSTATE_OP_SWITCHING_ON = ifw::fcf::devmgr::actuator::SUBSTATE_OP_SWITCHING_ON
 
const short testLampLcsIf::SUBSTATE_OP_WARMING = ifw::fcf::devmgr::lamp::SUBSTATE_OP_WARMING
 
const short testLampLcsIf::SUBSTATE_OP_ERROR = ifw::fcf::devmgr::common::SUBSTATE_OP_ERROR
 

Function Documentation

◆ MakeOk()

ifw::fnd::defs::Result ifw::fcf::devmgr::test::MakeOk ( )
inline

Build a generic "Ok" Result.

◆ MakeRpcReply()

ifw::fnd::defs::CallResult ifw::fcf::devmgr::test::MakeRpcReply ( short code,
ifw::fnd::defs::Status batch_status = ifw::fnd::defs::Status::Ok )
inline

Build a CallResult that carries a single short reply code, matching the convention every FCF RPC uses (RPC reply in output_arguments[0].data.value as short).