YARP
Yet Another Robot Platform
 
Loading...
Searching...
No Matches
simulatedWorld_nws_yarp_test.cpp
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2026-2026 Istituto Italiano di Tecnologia (IIT)
3 * SPDX-License-Identifier: BSD-3-Clause
4 */
5
6#include <yarp/os/Network.h>
7#include <yarp/sig/Vector.h>
10#include <yarp/os/Time.h>
11
12#include <string>
13
15#include <catch2/catch_amalgamated.hpp>
16#include <harness.h>
17
18using namespace yarp::os;
19using namespace yarp::dev;
20using namespace yarp::sig;
21
22
23TEST_CASE("dev::simulatedWorld_nws_yarp", "[yarp::dev]")
24{
25 YARP_REQUIRE_PLUGIN("fakeSimulatedWorld", "device");
26 YARP_REQUIRE_PLUGIN("simulatedWorld_nws_yarp", "device");
27
28 Network::setLocalMode(true);
29
30 SECTION("Test the simulatedWorld_nws_yarp device with no device attached")
31 {
34
35 p_nws.put("device","simulatedWorld_nws_yarp");
36 p_nws.put("name", "/sim_nws");
39
42 }
43
44 SECTION("Test the simulatedWorld_nws_yarp device with fakeSimulatedWorld device attached")
45 {
50
51 p_nws.put("device", "simulatedWorld_nws_yarp");
52 p_nws.put("name", "/sim_nws");
53 p_fake.put("device", "fakeSimulatedWorld");
57
60 bool result_att = ww_nws->attach(&dd_fake);
62
64
67 }
68
69 Network::setLocalMode(false);
70}
contains the definition of a Vector type
A container for a device driver.
Definition PolyDriver.h:23
Helper interface for an object that can wrap/or "attach" to a single other device.
A mini-server for performing network communication in the background.
void close() override
Stop port activity.
bool open(const std::string &name) override
Start port operation, with a specific name, with automatically-chosen network parameters.
A class for storing options and configuration information.
Definition Property.h:32
static void delaySystem(double seconds)
void exec_params_test(yarp::dev::PolyDriver *pdrv)
For streams capable of holding different kinds of content, check what they actually have.
An interface to the operating system, including Port based communication.
TEST_CASE("dev::simulatedWorld_nws_yarp", "[yarp::dev]")