-
Notifications
You must be signed in to change notification settings - Fork 182
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] add/improved IsPublished/IsSubscribed logic (master) #1633
Conversation
…IsSubscribed" (we may rename both functions to "IsConnected" in the future) new additional check for IsPublished using the connection state of the matching subscriber (should ensure that IsPublished is flagged as true only if publisher is able to send data) test added to test new 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
@@ -216,3 +216,97 @@ TEST(core_cpp_pubsub, SporadicEmptyReceives) | |||
// finalize eCAL API | |||
EXPECT_EQ(0, eCAL::Finalize()); | |||
} | |||
|
|||
TEST(PubSub, TestSubscriberSeen) |
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(PubSub, TestSubscriberSeen) | |
TEST(PubSub /*unused*/, TestSubscriberSeen /*unused*/) |
auto max_lines(10); | ||
auto receive_lambda = [&received, &max_lines](const char* /*topic_name_*/, const struct eCAL::SReceiveCallbackData* data_) | ||
{ | ||
if (max_lines) |
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: implicit conversion 'int' -> bool [readability-implicit-bool-conversion]
if (max_lines) | |
if (max_lines != 0) |
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.
👍
Description
Related issues