This is an automated email from the ASF dual-hosted git repository.
rabbah pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/openwhisk.git
The following commit(s) were added to refs/heads/master by this push:
new 66a9417 Add Tasks to failed test match. (#4959)
66a9417 is described below
commit 66a9417e9f9b66ea091a03b07048ac92093e7d74
Author: rodric rabbah <[email protected]>
AuthorDate: Thu Sep 3 09:45:39 2020 -0400
Add Tasks to failed test match. (#4959)
---
tools/build/citool | 7 ++++++-
1 file changed, 6 insertions(+), 1 deletion(-)
diff --git a/tools/build/citool b/tools/build/citool
index 82701e4..7a3b090 100755
--- a/tools/build/citool
+++ b/tools/build/citool
@@ -78,6 +78,7 @@ def parseArgs():
subparser = subparsers.add_parser('monitor', help='report passing or
failing tests (only failing tests by default)')
subparser.add_argument('-a', '--all', help='show all tests suites, passing
and failing', action='store_true')
+ subparser.add_argument('-r', '--relax', help='relax regex match to include
failed ansible tasks', action='store_true')
subparser.add_argument('-p', '--poll', help='repeat monitor every 10
seconds', action='store_true')
subparser = subparsers.add_parser('cat', help='concatenate logs from build
(limited to Jenkins)')
@@ -241,7 +242,11 @@ def grepForFailingTests(args, body):
print('No tests detected.')
# no tests: either build failure or task not yet reached, skip further
check
else:
- cmd = 'grep -E "^\w+\.*.*[>|>] \w*.* FAILED%s"' % ("|PASSED" if
args.all else "")
+ if args.relax:
+ # this will match failed ansible tasks as well
+ cmd = 'grep -E "^> Task *.* FAILED|^\w+\.*.*[>|>] \w*.*
FAILED%s"' % ("|PASSED" if args.all else "")
+ else:
+ cmd = 'grep -E "^> Task *.* FAILED|^[\w.]+\s*[>|>] \w*.*
FAILED%s"' % ("|PASSED" if args.all else "")
(time, output, error) = shell(cmd, body, args.verbose)
if output == '':
print('All tests passing.')