diff options
author | Humberto Ibarra <humberto.ibarra.lopez@intel.com> | 2016-05-18 11:17:59 -0500 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2016-05-19 09:05:19 +0100 |
commit | ce2dd24cedfa19f64b04c6b6e640918ab8c3de8b (patch) | |
tree | e911fcf1c4dd0da82ac8c4263fd5ac55fbb40297 /scripts/oe-selftest | |
parent | 978d450a527e1875bf7e1a0c5fdfa6ed5fa36998 (diff) | |
download | poky-ce2dd24cedfa19f64b04c6b6e640918ab8c3de8b.tar.gz |
scripts/oe-selftest: Improve listing by reducing unneeded spacing
The --list-tests option assumes a terminal of 150 characters wide,
which is clearly wrong. The output for this command is messy and
hard to understand for lower widths. Every command should look
good in a 80 characters terminal.
Unfortunately, this can't be done at the moment. The bad naming of
testcases have made the test names incredibly long.
This patch reduces spacing between columns and shows the tests
names in a concise and understandable way. The format is even the
same one required for running a testcase. Once the testcase naming
improves, this output will look even better.
[Yocto #9534]
(From OE-Core rev: 53da74155942febd520836cabf3aa727c53ce5ca)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'scripts/oe-selftest')
-rwxr-xr-x | scripts/oe-selftest | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/scripts/oe-selftest b/scripts/oe-selftest index 5e23ef0038..8cc2095c53 100755 --- a/scripts/oe-selftest +++ b/scripts/oe-selftest | |||
@@ -338,14 +338,14 @@ def list_tests(): | |||
338 | 338 | ||
339 | ts = get_all_tests() | 339 | ts = get_all_tests() |
340 | 340 | ||
341 | print '%-4s\t%-20s\t%-60s\t%-25s\t%-20s' % ('id', 'tag', 'name', 'class', 'module') | 341 | print '%-4s\t%-10s\t%-50s' % ('id', 'tag', 'test') |
342 | print '_' * 150 | 342 | print '_' * 80 |
343 | for t in ts: | 343 | for t in ts: |
344 | if isinstance(t.tctag, (tuple, list)): | 344 | if isinstance(t.tctag, (tuple, list)): |
345 | print '%-4s\t%-20s\t%-60s\t%-25s\t%-20s' % (t.tcid, ', '.join(t.tctag), t.tcname, t.tcclass, t.tcmodule) | 345 | print '%-4s\t%-10s\t%-50s' % (t.tcid, ', '.join(t.tctag), '.'.join([t.tcmodule, t.tcclass, t.tcname])) |
346 | else: | 346 | else: |
347 | print '%-4s\t%-20s\t%-60s\t%-25s\t%-20s' % (t.tcid, t.tctag, t.tcname, t.tcclass, t.tcmodule) | 347 | print '%-4s\t%-10s\t%-50s' % (t.tcid, t.tctag, '.'.join([t.tcmodule, t.tcclass, t.tcname])) |
348 | print '_' * 150 | 348 | print '_' * 80 |
349 | print 'Total found:\t %s' % len(ts) | 349 | print 'Total found:\t %s' % len(ts) |
350 | 350 | ||
351 | 351 | ||