Skip to content

Commit 12fa4e4

Browse files
committed
Doc should only provide doc and not tags
1 parent 5be1079 commit 12fa4e4

File tree

2 files changed

+2
-11
lines changed

2 files changed

+2
-11
lines changed

src/robotlibcore.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -114,9 +114,6 @@ def get_keyword_documentation(self, name):
114114
return inspect.getdoc(self.__init__) or ''
115115
kw = self.keywords[name]
116116
doc = inspect.getdoc(kw) or ''
117-
if kw.robot_tags:
118-
tags = 'Tags: {}'.format(', '.join(kw.robot_tags))
119-
doc = '{}\n\n{}'.format(doc, tags) if doc else tags
120117
return doc
121118

122119
def get_keyword_types(self, keyword_name):

utest/test_robotlibcore.py

Lines changed: 2 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -276,20 +276,14 @@ def test_get_keyword_documentation():
276276
assert doc('__init__') == 'Library init doc.'
277277

278278

279-
def test_embed_tags_to_doc_when_get_keyword_tags_is_not_called():
280-
doc = DynamicLibrary().get_keyword_documentation
281-
assert doc('tags') == 'Tags: tag, another tag'
282-
assert doc('doc_and_tags') == 'I got doc!\n\nTags: tag'
283-
284-
285279
def test_get_keyword_tags():
286280
lib = DynamicLibrary()
287281
tags = lib.get_keyword_tags
288282
doc = lib.get_keyword_documentation
289283
assert tags('tags') == ['tag', 'another tag']
290284
assert tags('doc_and_tags') == ['tag']
291-
assert doc('tags') == 'Tags: tag, another tag'
292-
assert doc('doc_and_tags').splitlines() == ['I got doc!', '', 'Tags: tag']
285+
assert doc('tags') == ''
286+
assert doc('doc_and_tags') == 'I got doc!'
293287

294288

295289
def test_library_cannot_be_class():

0 commit comments

Comments
 (0)