[ros-users] [Discourse.ros.org] [Quality Assurance] Input validation as a metric for quality
ros.discourse at gmail.com
Mon Jan 29 19:11:54 UTC 2018
[quote="tyagikunal, post:1, topic:3732"]
Id like to confess in advance that I dont know how to enforce or detect violations automatically, or even what all would constitute a violation of input validation since it might be a non-exhaustive list. Having said that, Im eager to know your views on the topic and to answer, clarify and discuss.
The [thread hyperlinked already](https://discourse.ros.org/t/design-by-contract/2405/27) points to a project where Python `hypothesis` is used for property based testing in ROS1. That would be a possible way to verify violations.
It could be even easier to integrate with ROS2 because the ROS2 infrastructure supports `pytest` out of the box with [ament_cmake_pytest](https://github.com/ament/ament_cmake/tree/master/ament_cmake_pytest). Python `hypothesis` integrates with `pytest` out-of-the-box. If you search in the [hypothesis readthedocs](http://hypothesis.readthedocs.io/en/latest/index.html) you will find out how it integrates with `pytest`. (BTW: [hypothesis-pytest](https://pypi.python.org/pypi/hypothesis-pytest) is legacy...)
[Visit Topic](https://discourse.ros.org/t/input-validation-as-a-metric-for-quality/3732/4) or reply to this email to respond.
More information about the ros-users