[ros-users] [Discourse.ros.org] [Quality Assurance] Pytest s…

Forside
Vedhæftede filer:
Indlæg som e-mail
+ (text/plain)
Slet denne besked
Besvar denne besked
Skribent: Alexander Rössler via ros-users
Dato:  
Til: ros-users
CC: Alexander Rössler
Emne: [ros-users] [Discourse.ros.org] [Quality Assurance] Pytest support for ROS / rostest


Hello everyone,

I want to stir some interest in supporting pytest for ROS. [pytest](https://docs.pytest.org/en/latest/) is a very popular unit testing framework for Python.

In my opinion, pytest is far easier to use than Python unittest and nosetests supported by ROS as of now. My personal experience says the easier something is to do, the likelier it is to be done. As we are talking about unit tests, an essential part of professional software development and QA, I think it's even more important here. I have outline more about why this is necessary in a [blog post.](https://machinekoder.com/testing-ros-powered-robots-pytest/)

The easiest way to support pytest within ROS is to use a new test runner that wraps pytest and extracts the JUnit XML output. Here is my attempt at doing that [ros_pytest](https://github.com/machinekoder/ros_pytest)

ROS seems to pick up the test data very well. However, I noticed that failing tests still don't trigger a failure when running rostests (but the log/terminal output shows the error). I would appreciate any input on why this is the case.

I joined the ROS community a few months ago and I want to make my first contribution to the project. So please let me know how if you think this is a good idea and how I can proceed.

Alex





---
[Visit Topic](https://discourse.ros.org/t/pytest-support-for-ros-rostest/4990/1) or reply to this email to respond.


If you do not want to receive messages from ros-users please use the unsubscribe link below. If you use the one above, you will stop all of ros-users from receiving updates.
______________________________________________________________________________
ros-users mailing list

http://lists.ros.org/mailman/listinfo/ros-users
Unsubscribe: <http://lists.ros.org/mailman//options/ros-users>