18#include <catch2/catch_amalgamated.hpp>
23 YARP_REQUIRE_PLUGIN(
"test_numbers1",
"portmonitor")
24 YARP_REQUIRE_PLUGIN(
"test_numbers2",
"portmonitor")
41 TestCase {
"fast_tcp", 1},
43 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+type.dll",2},
44 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+file1.test_numbers1+type1.dll", 3},
45 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+file1.test_numbers2+type1.dll", 4},
46 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers2+file1.test_numbers1+type1.dll", 3},
48 TestCase {
"fast_tcp+recv.portmonitor+type.dll+file.test_numbers1+type.dll",2},
49 TestCase {
"fast_tcp+recv.portmonitor+type.dll+file.test_numbers1+file1.test_numbers1+type1.dll", 3},
50 TestCase {
"fast_tcp+recv.portmonitor+type.dll+file.test_numbers1+file1.test_numbers2+type1.dll", 4},
51 TestCase {
"fast_tcp+recv.portmonitor+type.dll+file.test_numbers2+file1.test_numbers1+type1.dll", 3},
53 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+type.dll+recv.portmonitor+type.dll+file.test_numbers1+type.dll",3},
54 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+file1.test_numbers1+type1.dll+recv.portmonitor+type.dll+file.test_numbers1+file1.test_numbers1+type1.dll", 5},
55 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers1+file1.test_numbers2+type1.dll+recv.portmonitor+type.dll+file.test_numbers1+file1.test_numbers2+type1.dll", 10},
56 TestCase {
"fast_tcp+send.portmonitor+type.dll+file.test_numbers2+file1.test_numbers1+type1.dll+recv.portmonitor+type.dll+file.test_numbers2+file1.test_numbers1+type1.dll", 7}
59 SECTION(
"Test that normally the portmonitor is not used")
65 receiver.
open(
"/recv");
76 CHECK(rval.
asInt64()==tc.expected_value);
static Carrier * getCarrierTemplate(const std::string &name)
Get template for carrier.
static bool connect(const std::string &src, const std::string &dest, const std::string &carrier="", bool quiet=true)
Request that an output port connect to an input port.
static bool setLocalMode(bool flag)
Chooses whether communication is process-local.
Utilities for manipulating the YARP network, including initialization and shutdown.
A mini-server for network communication.
bool write(const PortWriter &writer, const PortWriter *callback=nullptr) const override
Write an object to the port.
bool read(PortReader &reader, bool willReply=false) override
Read an object from the port.
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 single value (typically within a Bottle).
virtual std::int64_t asInt64() const
Get 64-bit integer value.
void delay(double seconds)
Wait for a certain number of seconds.
The main, catch-all namespace for YARP.
TEST_CASE("pm::test_numbersTest", "[yarp::pm]")