Skip to content

Commit

Permalink
jsk_tools/src/test_topic_published.py: set default timeout to 10 sec
Browse files Browse the repository at this point in the history
  • Loading branch information
k-okada committed Apr 27, 2016
1 parent a7292b9 commit ae66a5c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion jsk_tools/src/jsk_tools/sanity_lib.py
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ def __init__(self, topic_name, timeout=5, echo=False, data_class=None):
self.launched_time = rospy.Time.now()
self.first_time_callback = True
self.echo = echo
print " Checking %s at %d Hz" % (topic_name, timeout)
print " Checking %s for %d seconds" % (topic_name, timeout)
msg_class, _, _ = rostopic.get_topic_class(topic_name, blocking=True)
if (data_class is not None) and (msg_class is not data_class):
raise rospy.ROSException('Topic msg type is different.')
Expand Down
2 changes: 1 addition & 1 deletion jsk_tools/src/test_topic_published.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def __init__(self, *args):
continue
self.topics.append(value)
id = name.replace('topic_', '')
self.timeouts.append(rospy.get_param('~timeout_{}'.format(id)))
self.timeouts.append(rospy.get_param('~timeout_{}'.format(id), 10))
self.negatives.append(
rospy.get_param('~negative_{}'.format(id), False))
if not self.topics:
Expand Down

0 comments on commit ae66a5c

Please sign in to comment.