UniversalRobots / Universal_Robots_Client_Library

A C++ library for accessing the UR interfaces that facilitate the use of UR robotic manipulators by external applications.
Apache License 2.0
123 stars 91 forks source link

Added tests for the control interface classes #112

Closed urmahp closed 2 years ago

fmauch commented 2 years ago

Let's rebase this once #107 got merged.

fmauch commented 2 years ago

Rebased onto current master so all CI step should succeed.

codecov-commenter commented 2 years ago

Codecov Report

Base: 41.13% // Head: 51.29% // Increases project coverage by +10.16% :tada:

Coverage data is based on head (5f4680b) compared to base (f31f998). Patch coverage: 95.90% of modified lines in pull request are covered.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #112 +/- ## =========================================== + Coverage 41.13% 51.29% +10.16% =========================================== Files 76 82 +6 Lines 2064 2462 +398 Branches 256 279 +23 =========================================== + Hits 849 1263 +414 + Misses 1102 1069 -33 - Partials 113 130 +17 ``` | [Impacted Files](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots) | Coverage Δ | | |---|---|---| | [tests/test\_script\_sender.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-dGVzdHMvdGVzdF9zY3JpcHRfc2VuZGVyLmNwcA==) | `93.18% <93.18%> (ø)` | | | [tests/test\_trajectory\_point\_interface.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-dGVzdHMvdGVzdF90cmFqZWN0b3J5X3BvaW50X2ludGVyZmFjZS5jcHA=) | `95.28% <95.28%> (ø)` | | | [tests/test\_reverse\_interface.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-dGVzdHMvdGVzdF9yZXZlcnNlX2ludGVyZmFjZS5jcHA=) | `97.18% <97.18%> (ø)` | | | [src/control/reverse\_interface.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-c3JjL2NvbnRyb2wvcmV2ZXJzZV9pbnRlcmZhY2UuY3Bw) | `86.53% <100.00%> (+86.53%)` | :arrow_up: | | [src/ur/ur\_driver.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-c3JjL3VyL3VyX2RyaXZlci5jcHA=) | `0.00% <0.00%> (ø)` | | | [src/rtde/data\_package.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-c3JjL3J0ZGUvZGF0YV9wYWNrYWdlLmNwcA==) | `62.50% <0.00%> (ø)` | | | [include/ur\_client\_library/types.h](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-aW5jbHVkZS91cl9jbGllbnRfbGlicmFyeS90eXBlcy5o) | `0.00% <0.00%> (ø)` | | | [include/ur\_client\_library/ur/ur\_driver.h](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-aW5jbHVkZS91cl9jbGllbnRfbGlicmFyeS91ci91cl9kcml2ZXIuaA==) | `0.00% <0.00%> (ø)` | | | [include/ur\_client\_library/comm/tcp\_socket.h](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-aW5jbHVkZS91cl9jbGllbnRfbGlicmFyeS9jb21tL3RjcF9zb2NrZXQuaA==) | `0.00% <0.00%> (ø)` | | | [src/control/script\_command\_interface.cpp](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots#diff-c3JjL2NvbnRyb2wvc2NyaXB0X2NvbW1hbmRfaW50ZXJmYWNlLmNwcA==) | `0.00% <0.00%> (ø)` | | | ... and [14 more](https://codecov.io/gh/UniversalRobots/Universal_Robots_Client_Library/pull/112/diff?src=pr&el=tree-more&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots) | | Help us with your feedback. Take ten seconds to tell us [how you rate us](https://about.codecov.io/nps?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots). Have a feature suggestion? [Share it here.](https://app.codecov.io/gh/feedback/?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=UniversalRobots)

:umbrella: View full report at Codecov.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.

urmahp commented 2 years ago

Looks good to me. Moving the setup into the fixtures is a debatable feature, so I'll approve this, but will only merge this after discussing that topic.

I think it would be a good idea to make the setup part of the fixture, since it is identical for all the tests, so I will have a look at that.

fmauch commented 2 years ago

Squashed to re-trigger code-cov report.

fmauch commented 2 years ago

Just for clarity: This is currently being held back as @urmahp wanted to move code to the test fixture. Once this is done, this should be ready to merge.