Skip to content

Commit

Permalink
Merge pull request #847 from kopp/fix_docu_nosetests_846
Browse files Browse the repository at this point in the history
Minor changes in docu: Build messages for test
  • Loading branch information
dirk-thomas committed Jan 20, 2017
2 parents 51ef314 + 2119c2f commit 1843178
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 0 deletions.
14 changes: 14 additions & 0 deletions doc/howto/format1/python_nose_configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ You can also let nosetest find all tests recursively::
catkin_add_nosetests(tests)
endif()

If you used a message of the current package in the nosetest, make sure to
specify the nosetest like this::

catkin_add_nosetests(tests/test_your_node.py
DEPENDENCIES ${${PROJECT_NAME}_EXPORTED_TARGETS})

If you used messages from other packages, use::

catkin_add_nosetests(tests/test_your_node.py
DEPENDENCIES ${catkin_EXPORTED_TARGETS})

The test will then make sure that the messages used in the test are built
before they are used.

For more info, please have a look at the :ref:`API <catkin_add_nosetests_ref>`.

.. _Nosetest: http://www.ros.org/wiki/nosetest
Expand Down
14 changes: 14 additions & 0 deletions doc/howto/format2/python_nose_configuration.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,6 +26,20 @@ You can also let nosetest find all tests recursively::
catkin_add_nosetests(tests)
endif()

If you used a message of the current package in the nosetest, make sure to
specify the nosetest like this::

catkin_add_nosetests(tests/test_your_node.py
DEPENDENCIES ${${PROJECT_NAME}_EXPORTED_TARGETS})

If you used messages from other packages, use::

catkin_add_nosetests(tests/test_your_node.py
DEPENDENCIES ${catkin_EXPORTED_TARGETS})

The test will then make sure that the messages used in the test are built
before they are used.

For more info, please have a look at the :ref:`API <catkin_add_nosetests_ref>`.

.. _Nosetest: http://www.ros.org/wiki/nosetest
Expand Down

0 comments on commit 1843178

Please sign in to comment.