提交 adbfa281 编写于 作者: C Cleber Rosa

List: add support for values in tags

When listing tests in verbose mode, tags get shown.  But since the
addition of key:val tags, the values are not being shown.

To allow for a compact layout, this puts the values under parenthesis
right after the key.
Signed-off-by: NCleber Rosa <crosa@redhat.com>
上级 2be2eab2
......@@ -75,14 +75,19 @@ class TestLister:
if 'tags' in params:
tags = params['tags']
else:
tags = set()
for tag in tags:
tags = {}
tags_repr = []
for tag, vals in tags.items():
if tag not in tag_stats:
tag_stats[tag] = 1
else:
tag_stats[tag] += 1
tags = ",".join(tags)
test_matrix.append((type_label, params['name'], tags))
if vals:
tags_repr.append("%s(%s)" % (tag, ",".join(vals)))
else:
tags_repr.append(tag)
tags_repr = ",".join(tags_repr)
test_matrix.append((type_label, params['name'], tags_repr))
else:
test_matrix.append((type_label, params['name']))
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册