Skip to content
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

Fast DDS Spy tool tests #21

Merged
merged 63 commits into from
Jun 22, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
e52e401
Add tool tests
irenebm Mar 27, 2023
e869b7f
Update
irenebm Mar 27, 2023
32477a3
Fix python linter
irenebm Mar 27, 2023
528ec6a
AApply changes
irenebm Mar 28, 2023
0e69b27
Fail test
irenebm Mar 28, 2023
7c50a6c
Without one shot
irenebm Mar 28, 2023
0a9f145
Fix tsan
irenebm Mar 28, 2023
27733c9
add commands
irenebm Mar 28, 2023
762dae0
Update structure
irenebm Mar 28, 2023
90af7a3
Change structure
irenebm Mar 28, 2023
2963a76
Add one shot test without dds
irenebm Mar 28, 2023
ffca21e
Update
irenebm Mar 29, 2023
95d8eb2
Working without fast
irenebm Mar 29, 2023
632bf18
Add one shot with dds tests
irenebm Mar 29, 2023
ef4e0c9
Add dds publisher
irenebm Mar 30, 2023
bda5860
Get output commands
irenebm Mar 30, 2023
b684173
Rename function
irenebm Mar 30, 2023
11b026f
Test output without dds working
irenebm Mar 30, 2023
6ab987f
Everything working except for tool with dds
irenebm Mar 30, 2023
610fb0e
Add xtsan flag to dds tests
irenebm Mar 30, 2023
728f56b
Update
irenebm Mar 30, 2023
21daf16
Rate with regexp
irenebm Mar 31, 2023
ff56f55
Everything working
irenebm Mar 31, 2023
23275fc
Add signal windows
irenebm Apr 5, 2023
03dabfb
More coverage
irenebm Apr 13, 2023
4ad8d72
Fix tests
irenebm Apr 13, 2023
4461703
Long lines
irenebm Apr 13, 2023
d077c34
Long lines
irenebm Apr 13, 2023
186b08a
Some style fixes
irenebm Apr 14, 2023
0f995c6
Some fixes windows
irenebm Apr 17, 2023
11bca15
Some fixes windows
irenebm Apr 17, 2023
4ec0111
Signal windows
irenebm Apr 17, 2023
6859097
Fix local path dds
irenebm Apr 17, 2023
c921d95
Fix one shot
irenebm Apr 17, 2023
1fe405a
Some fixes
irenebm Apr 17, 2023
830beba
Fix return
irenebm Apr 17, 2023
e723c4e
Some fixes
irenebm Apr 17, 2023
b1e12ae
Some fixes
irenebm Apr 17, 2023
88b5705
Without return code
irenebm Apr 17, 2023
865ff71
Update
irenebm Apr 17, 2023
5186bd8
Some fixes
irenebm Apr 21, 2023
59ff746
Time changes
irenebm Apr 21, 2023
642dd9d
Fix time, uncrustify and python linter
irenebm Apr 21, 2023
ef5ecf1
Uncrustify and more timeout
irenebm Apr 21, 2023
2b3c966
add lease_duration
irenebm Apr 24, 2023
5a9d116
More timeout
irenebm Apr 24, 2023
97e5476
add stop when fail
irenebm Apr 28, 2023
db3e8fe
Add Release path
irenebm May 4, 2023
e6188a0
Fix stop tool when wrong output and sys.exit(0)
irenebm May 23, 2023
a7165e3
Fix exit and give time to stop
irenebm May 23, 2023
ff1d9af
Less timeout
irenebm May 23, 2023
7d927ea
timeout=15
irenebm May 23, 2023
208ffb9
Fix python linter
irenebm May 23, 2023
1b237bf
Give more time to stop
irenebm May 23, 2023
0cf9a3d
change kill publisher
irenebm May 23, 2023
938f640
kill publisher
irenebm May 23, 2023
f4239f7
Apply changes
irenebm May 23, 2023
a8ebe77
Testing
irenebm May 23, 2023
f50431f
Add docu code
irenebm May 24, 2023
c05f028
Debug
irenebm May 29, 2023
bc1849e
Apply changes
irenebm Jun 9, 2023
d5fc618
Apply changes
irenebm Jun 21, 2023
701426c
Apply changes
irenebm Jun 21, 2023
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -29,52 +29,52 @@ struct ModelParser
{
FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<SimpleParticipantData> participants(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<ComplexParticipantData> participants_verbose(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static ComplexParticipantData participants(
const SpyModel& model,
const ddspipe::core::types::Guid& guid);
const ddspipe::core::types::Guid& guid) noexcept;

FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<SimpleEndpointData> writers(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<ComplexEndpointData> writers_verbose(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static ComplexEndpointData writers(
const SpyModel& model,
const ddspipe::core::types::Guid& guid);
const ddspipe::core::types::Guid& guid) noexcept;

FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<SimpleEndpointData> readers(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<ComplexEndpointData> readers_verbose(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static ComplexEndpointData readers(
const SpyModel& model,
const ddspipe::core::types::Guid& guid);
const ddspipe::core::types::Guid& guid) noexcept;

FASTDDSSPY_PARTICIPANTS_DllAPI
static ddspipe::core::types::DdsTopic get_topic(
const SpyModel& model,
std::string topic_name);
std::string topic_name) noexcept;

FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<SimpleTopicData> topics(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static std::vector<ComplexTopicData> topics_verbose(
const SpyModel& model);
const SpyModel& model) noexcept;
FASTDDSSPY_PARTICIPANTS_DllAPI
static ComplexTopicData topics(
const SpyModel& model,
const std::string& topic_name);
const std::string& topic_name) noexcept;
};

} /* namespace participants */
Expand Down
40 changes: 20 additions & 20 deletions fastddsspy_participants/src/cpp/visualization/ModelParser.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ namespace spy {
namespace participants {

std::vector<SimpleParticipantData> ModelParser::participants(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<SimpleParticipantData> result;
for (const auto& it : model.participant_database_)
Expand All @@ -36,7 +36,7 @@ std::vector<SimpleParticipantData> ModelParser::participants(
}

std::vector<ComplexParticipantData> ModelParser::participants_verbose(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<ComplexParticipantData> result;

Expand All @@ -56,7 +56,7 @@ void add_endpoint_to_vector(
std::map<std::string, int>& already_endpoints_index,
std::vector<ComplexParticipantData::Endpoint>& endpoints,
const std::pair<const eprosima::ddspipe::core::types::Guid,
eprosima::spy::participants::EndpointInfo>& endpoint)
eprosima::spy::participants::EndpointInfo>& endpoint) noexcept
{
// Check if this topic has already endpoints added
auto it = already_endpoints_index.find(endpoint.second.topic.m_topic_name);
Expand All @@ -79,7 +79,7 @@ void add_endpoint_to_vector(

ComplexParticipantData ModelParser::participants(
const SpyModel& model,
const ddspipe::core::types::Guid& guid)
const ddspipe::core::types::Guid& guid) noexcept
{
ComplexParticipantData result;

Expand Down Expand Up @@ -126,7 +126,7 @@ ComplexParticipantData ModelParser::participants(

std::string get_participant_name(
const SpyModel& model,
const ddspipe::core::types::Guid guid)
const ddspipe::core::types::Guid guid) noexcept
{
// Look for participant name
for (const auto& participant : model.participant_database_)
Expand All @@ -142,7 +142,7 @@ std::string get_participant_name(

SimpleEndpointData fill_simple_endpoint(
const SpyModel& model,
const spy::participants::EndpointInfo& endpoint)
const spy::participants::EndpointInfo& endpoint) noexcept
{
std::string participant_name = get_participant_name(model, endpoint.guid);

Expand All @@ -159,7 +159,7 @@ SimpleEndpointData fill_simple_endpoint(
void fill_complex_endpoint(
const SpyModel& model,
ComplexEndpointData& result,
const spy::participants::EndpointInfo& endpoint)
const spy::participants::EndpointInfo& endpoint) noexcept
{
result.participant_name = get_participant_name(model, endpoint.guid);

Expand All @@ -173,7 +173,7 @@ void fill_complex_endpoint(
void set_endpoint_simple_information(
const SpyModel& model,
std::vector<SimpleEndpointData>& result,
const ddspipe::core::types::EndpointKind kind)
const ddspipe::core::types::EndpointKind kind) noexcept
{
for (const auto& endpoint : model.endpoint_database_)
{
Expand All @@ -188,7 +188,7 @@ void set_endpoint_complex_information(
const SpyModel& model,
ComplexEndpointData& result,
const ddspipe::core::types::EndpointKind kind,
const eprosima::ddspipe::core::types::Guid guid)
const eprosima::ddspipe::core::types::Guid guid) noexcept
{
for (const auto& endpoint : model.endpoint_database_)
{
Expand All @@ -202,7 +202,7 @@ void set_endpoint_complex_information(
}

std::vector<SimpleEndpointData> ModelParser::writers(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<SimpleEndpointData> result;

Expand All @@ -212,7 +212,7 @@ std::vector<SimpleEndpointData> ModelParser::writers(
}

std::vector<ComplexEndpointData> ModelParser::writers_verbose(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<ComplexEndpointData> result;

Expand All @@ -229,7 +229,7 @@ std::vector<ComplexEndpointData> ModelParser::writers_verbose(

ComplexEndpointData ModelParser::writers(
const SpyModel& model,
const ddspipe::core::types::Guid& guid)
const ddspipe::core::types::Guid& guid) noexcept
{
ComplexEndpointData result;

Expand All @@ -239,7 +239,7 @@ ComplexEndpointData ModelParser::writers(
}

std::vector<SimpleEndpointData> ModelParser::readers(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<SimpleEndpointData> result;

Expand All @@ -249,7 +249,7 @@ std::vector<SimpleEndpointData> ModelParser::readers(
}

std::vector<ComplexEndpointData> ModelParser::readers_verbose(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<ComplexEndpointData> result;

Expand All @@ -266,7 +266,7 @@ std::vector<ComplexEndpointData> ModelParser::readers_verbose(

ComplexEndpointData ModelParser::readers(
const SpyModel& model,
const ddspipe::core::types::Guid& guid)
const ddspipe::core::types::Guid& guid) noexcept
{
ComplexEndpointData result;

Expand All @@ -279,7 +279,7 @@ ComplexEndpointData ModelParser::readers(
* This is an auxiliary function that is used to get topics endpoint database
*/
std::set<eprosima::ddspipe::core::types::DdsTopic> get_topics(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::set<eprosima::ddspipe::core::types::DdsTopic> result;
for (const auto& endpoint : model.endpoint_database_)
Expand All @@ -294,7 +294,7 @@ std::set<eprosima::ddspipe::core::types::DdsTopic> get_topics(

ddspipe::core::types::DdsTopic ModelParser::get_topic(
const SpyModel& model,
std::string topic_name)
std::string topic_name) noexcept
{

for (const auto& endpoint : model.endpoint_database_)
Expand All @@ -309,7 +309,7 @@ ddspipe::core::types::DdsTopic ModelParser::get_topic(
}

std::vector<SimpleTopicData> ModelParser::topics(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<SimpleTopicData> result;

Expand Down Expand Up @@ -348,7 +348,7 @@ std::vector<SimpleTopicData> ModelParser::topics(
}

std::vector<ComplexTopicData> ModelParser::topics_verbose(
const SpyModel& model)
const SpyModel& model) noexcept
{
std::vector<ComplexTopicData> result;

Expand All @@ -363,7 +363,7 @@ std::vector<ComplexTopicData> ModelParser::topics_verbose(

ComplexTopicData ModelParser::topics(
const SpyModel& model,
const std::string& topic_name)
const std::string& topic_name) noexcept
{
ComplexTopicData result;

Expand Down
2 changes: 2 additions & 0 deletions fastddsspy_tool/package.xml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@

<buildtool_depend>cmake</buildtool_depend>

<depend>cmake_utils</depend>
<depend>cpp_utils</depend>
<depend>py_utils</depend>
<depend>ddspipe_core</depend>
<depend>ddspipe_participants</depend>
<depend>ddspipe_yaml</depend>
Expand Down
4 changes: 4 additions & 0 deletions fastddsspy_tool/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.

# Add subdirectory with labels for tests
add_subdirectory(labels)

# Add subdirectory with tests
add_subdirectory(application)
Loading