Fix perf_test_runner printing wrong test name
The previous version of the script would always print the default test
name even if user specified a different one.
BUG=angleproject:596
Change-Id: I43a07e81b49f69c7c372b46bd9494d6fe440b968
Reviewed-on: https://chromium-review.googlesource.com/319091
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Tested-by: Olli Etuaho <oetuaho@nvidia.com>
diff --git a/scripts/perf_test_runner.py b/scripts/perf_test_runner.py
index db8e93b..5934a0e 100644
--- a/scripts/perf_test_runner.py
+++ b/scripts/perf_test_runner.py
@@ -76,12 +76,12 @@
test_name = "DrawCallPerfBenchmark.Run/d3d11_null"
-print('Using test executable: ' + perftests_path)
-print('Test name: ' + test_name)
-
if len(sys.argv) >= 2:
test_name = sys.argv[1]
+print('Using test executable: ' + perftests_path)
+print('Test name: ' + test_name)
+
# Infinite loop of running the tests.
while True:
output = subprocess.check_output([perftests_path, '--gtest_filter=' + test_name])