Skip to content
This repository was archived by the owner on May 31, 2025. It is now read-only.

Clean the namespace to get rid of double or trailing forward slashes …#1100

Merged
dirk-thomas merged 4 commits intoros:lunar-develfrom
lucasw:sanitize-thisnode-namespace
Jul 19, 2017
Merged

Clean the namespace to get rid of double or trailing forward slashes …#1100
dirk-thomas merged 4 commits intoros:lunar-develfrom
lucasw:sanitize-thisnode-namespace

Conversation

@lucasw
Copy link
Copy Markdown
Contributor

@lucasw lucasw commented Jul 14, 2017

#1094

This cleans the namespace provided to this_node, getting rid of excess slashes ('//' becomes '/').

@nuclearsandwich
Copy link
Copy Markdown
Member

@ros-pull-request-builder retest this please.

@lucasw
Copy link
Copy Markdown
Contributor Author

lucasw commented Jul 18, 2017

(How to build and run the tests:

sudo apt-get install python-ros-buildfarm
cd ~/lunar_catkin_ws
catkin_make_isolated_and_test.py --rosdistro-name lunar --workspace-root .

-but then on one of my systems this is failing all over:

FAILURE: test [paramtest_value_specific_correct] did not generate test results
  File "/usr/lib/python2.7/unittest/case.py", line 329, in run
    testMethod()
  File "/home/lucasw/lunar_catkin_ws/src/ros_comm/tools/rostest/src/rostest/runner.py", line 164, in fn
    self.assert_(os.path.isfile(test_file), "test [%s] did not generate test results"%test_name)
  File "/usr/lib/python2.7/unittest/case.py", line 422, in assertTrue
    raise self.failureException(msg)

Then how to run just the namespace test?

source devel_isolated/setup.bash
rostest src/ros_comm/test/test_roscpp/test/launch/namespaces.xml

)

@dirk-thomas
Copy link
Copy Markdown
Member

The patch looks good. Thank you. Merging...

How to build and run the tests:

Please see the docs for the ros_buildfarm repo (https://github.com/ros-infrastructure/ros_buildfarm/blob/master/doc/jobs/devel_jobs.rst#run-the-devel-job-locally) for this. It only supports running the job within Docker though.

@dirk-thomas dirk-thomas merged commit a4e5f67 into ros:lunar-devel Jul 19, 2017
sputnick1124 pushed a commit to sputnick1124/ros_comm that referenced this pull request Jul 30, 2017
ros#1100)

* Clean the namespace to get rid of double or trailing forward slashes ros#1094

* Get rid of extra slashes in namespace ros#1094

* names::clean() will turn a '/' into '' (is that a bug or desired?), but also prefix a slash as needed, so accommodating that here.  ros#1094

* Simplifying and fixing, now namespaces.xml test passes. ros#1094
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants