-
Notifications
You must be signed in to change notification settings - Fork 174
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[core] new-datarw-connection-logic #1729
Conversation
…get IsPublished/IsSubscribed (and the connection events) only if the connection is fully established connection state need now a second registration loop to get fully active Send(), Receive() functions are not affected by the new state handling test added to check correct IsPublished() and IsSubscribed() behavior
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
clang-tidy made some suggestions
#include <string> | ||
#include <thread> | ||
|
||
#include <gtest/gtest.h> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: 'gtest/gtest.h' file not found [clang-diagnostic-error]
#include <gtest/gtest.h>
^
|
||
#include <gtest/gtest.h> | ||
|
||
TEST(core_cpp_pubsub, TestSubscriberIsPublishedTiming) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: all parameters should be named in a function [readability-named-parameter]
TEST(core_cpp_pubsub, TestSubscriberIsPublishedTiming) | |
TEST(core_cpp_pubsub /*unused*/, TestSubscriberIsPublishedTiming /*unused*/) |
std::string first_received_sample; | ||
auto subscriber_thread = [&]() { | ||
eCAL::CSubscriber sub("blob"); | ||
bool received(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'received' of type 'bool' can be declared 'const' [misc-const-correctness]
bool received(false); | |
bool const received(false); |
eCAL::Finalize(); | ||
} | ||
|
||
TEST(core_cpp_pubsub, TestPublisherIsSubscribedTiming) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: all parameters should be named in a function [readability-named-parameter]
TEST(core_cpp_pubsub, TestPublisherIsSubscribedTiming) | |
TEST(core_cpp_pubsub /*unused*/, TestPublisherIsSubscribedTiming /*unused*/) |
std::string first_received_sample; | ||
auto subscriber_thread = [&]() { | ||
eCAL::CSubscriber sub("blob"); | ||
bool received(false); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
warning: variable 'received' of type 'bool' can be declared 'const' [misc-const-correctness]
bool received(false); | |
bool const received(false); |
…com/eclipse-ecal/ecal into feature/new-datarw-connection-logic
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💻 lgtm 👍
Description
Refactor connection state logic for DataReader/Writer (Sub/Pub)