diff options
author | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-07-22 23:30:15 +0100 |
---|---|---|
committer | Richard Purdie <richard.purdie@linuxfoundation.org> | 2015-07-23 08:48:41 +0100 |
commit | 901be2cb69892595443ed41ab4be285932db15eb (patch) | |
tree | 1021fffcb51cdf347d1643b2516b691c3505a8f1 /bitbake/bin | |
parent | aaea533e70d4aefc2de3a2a62a3453a2a9034292 (diff) | |
download | poky-901be2cb69892595443ed41ab4be285932db15eb.tar.gz |
bitbake: bitbake-selftest: Add -v option for verbosity
Also document BB_SKIP_NETTESTS=yes parameter in --help output.
(Bitbake rev: 5196bfa9639eed2b1e6452f45775551203f8eeb4)
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'bitbake/bin')
-rwxr-xr-x | bitbake/bin/bitbake-selftest | 15 |
1 files changed, 10 insertions, 5 deletions
diff --git a/bitbake/bin/bitbake-selftest b/bitbake/bin/bitbake-selftest index 8db6197d2f..462eb1b2b4 100755 --- a/bitbake/bin/bitbake-selftest +++ b/bitbake/bin/bitbake-selftest | |||
@@ -26,14 +26,19 @@ except RuntimeError as exc: | |||
26 | sys.exit(str(exc)) | 26 | sys.exit(str(exc)) |
27 | 27 | ||
28 | def usage(): | 28 | def usage(): |
29 | print('usage: %s [testname1 [testname2]...]' % os.path.basename(sys.argv[0])) | 29 | print('usage: [BB_SKIP_NETTESTS=yes] %s [-v] [testname1 [testname2]...]' % os.path.basename(sys.argv[0])) |
30 | 30 | ||
31 | if len(sys.argv) > 1: | 31 | verbosity = 1 |
32 | |||
33 | tests = sys.argv[1:] | ||
34 | if '-v' in sys.argv: | ||
35 | tests.remove('-v') | ||
36 | verbosity = 2 | ||
37 | |||
38 | if tests: | ||
32 | if '--help' in sys.argv[1:]: | 39 | if '--help' in sys.argv[1:]: |
33 | usage() | 40 | usage() |
34 | sys.exit(0) | 41 | sys.exit(0) |
35 | |||
36 | tests = sys.argv[1:] | ||
37 | else: | 42 | else: |
38 | tests = ["bb.tests.codeparser", | 43 | tests = ["bb.tests.codeparser", |
39 | "bb.tests.cow", | 44 | "bb.tests.cow", |
@@ -46,5 +51,5 @@ for t in tests: | |||
46 | t = '.'.join(t.split('.')[:3]) | 51 | t = '.'.join(t.split('.')[:3]) |
47 | __import__(t) | 52 | __import__(t) |
48 | 53 | ||
49 | unittest.main(argv=["bitbake-selftest"] + tests) | 54 | unittest.main(argv=["bitbake-selftest"] + tests, verbosity=verbosity) |
50 | 55 | ||