Skip to content

Commit

Permalink
Fixed a couple places not updated with new jobset.run() return values.
Browse files Browse the repository at this point in the history
  • Loading branch information
adelez committed Oct 23, 2015
1 parent 51b6eae commit f2ca7bc
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions tools/run_tests/run_tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -839,14 +839,14 @@ def _build_and_run(
root = ET.Element('testsuites') if xml_report else None
testsuite = ET.SubElement(root, 'testsuite', id='1', package='grpc', name='tests') if xml_report else None

if not jobset.run(all_runs, check_cancelled,
newline_on_success=newline_on_success, travis=travis,
infinite_runs=infinite_runs,
maxjobs=args.jobs,
stop_on_failure=args.stop_on_failure,
cache=cache if not xml_report else None,
xml_report=testsuite,
add_env={'GRPC_TEST_PORT_SERVER': 'localhost:%d' % port_server_port}):
number_failures, _ = jobset.run(
all_runs, check_cancelled, newline_on_success=newline_on_success,
travis=travis, infinite_runs=infinite_runs, maxjobs=args.jobs,
stop_on_failure=args.stop_on_failure,
cache=cache if not xml_report else None,
xml_report=testsuite,
add_env={'GRPC_TEST_PORT_SERVER': 'localhost:%d' % port_server_port})
if number_failures:
return 2
finally:
for antagonist in antagonists:
Expand All @@ -855,8 +855,10 @@ def _build_and_run(
tree = ET.ElementTree(root)
tree.write(xml_report, encoding='UTF-8')

if not jobset.run(post_tests_steps, maxjobs=1, stop_on_failure=True,
newline_on_success=newline_on_success, travis=travis):
number_failures, _ = jobset.run(
post_tests_steps, maxjobs=1, stop_on_failure=True,
newline_on_success=newline_on_success, travis=travis)
if number_failures:
return 3

if cache: cache.save()
Expand Down

0 comments on commit f2ca7bc

Please sign in to comment.