Skip to content

Commit 643cafc

Browse files
committed
Reduce diff
1 parent 8d3a5c5 commit 643cafc

File tree

1 file changed

+5
-6
lines changed

1 file changed

+5
-6
lines changed

python/run-tests.py

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,7 @@ def run_individual_python_test(target_dir, test_name, pyspark_python):
9292
"--conf", "spark.executor.extraJavaOptions=-Djava.io.tmpdir={0}".format(tmp_dir),
9393
"pyspark-shell"
9494
]
95+
9596
env["PYSPARK_SUBMIT_ARGS"] = " ".join(spark_args)
9697
LOGGER.info("Starting test(%s): %s", pyspark_python, test_name)
9798
start_time = time.time()
@@ -102,8 +103,7 @@ def run_individual_python_test(target_dir, test_name, pyspark_python):
102103
stderr=per_test_output, stdout=per_test_output, env=env).wait()
103104
shutil.rmtree(tmp_dir, ignore_errors=True)
104105
except:
105-
LOGGER.exception(
106-
"Got exception while running %s with %s", test_name, pyspark_python)
106+
LOGGER.exception("Got exception while running %s with %s", test_name, pyspark_python)
107107
# Here, we use os._exit() instead of sys.exit() in order to force Python to exit even if
108108
# this code is invoked from a thread other than the main thread.
109109
os._exit(1)
@@ -124,8 +124,7 @@ def run_individual_python_test(target_dir, test_name, pyspark_python):
124124
except:
125125
LOGGER.exception("Got an exception while trying to print failed test output")
126126
finally:
127-
print_red("\nHad test failures in %s with %s; see logs." % (
128-
test_name, pyspark_python))
127+
print_red("\nHad test failures in %s with %s; see logs." % (test_name, pyspark_python))
129128
# Here, we use os._exit() instead of sys.exit() in order to force Python to exit even if
130129
# this code is invoked from a thread other than the main thread.
131130
os._exit(-1)
@@ -153,8 +152,8 @@ def run_individual_python_test(target_dir, test_name, pyspark_python):
153152
os._exit(-1)
154153
if skipped_counts != 0:
155154
LOGGER.info(
156-
"Finished test(%s): %s (%is) ... %s tests were skipped", pyspark_python,
157-
test_name, duration, skipped_counts)
155+
"Finished test(%s): %s (%is) ... %s tests were skipped", pyspark_python, test_name,
156+
duration, skipped_counts)
158157
else:
159158
LOGGER.info(
160159
"Finished test(%s): %s (%is)", pyspark_python, test_name, duration)

0 commit comments

Comments
 (0)