summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbrettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-14 22:32:13 +0000
committerbrettw@google.com <brettw@google.com@0039d316-1c4b-4281-b951-d872f2087c98>2008-10-14 22:32:13 +0000
commit1a84e8ebf01c44c3af3810e62b13b25174cf4e03 (patch)
tree20beaf978498b0c9745ae418846a7981c08ff3a4
parentb11166864ae00b187390b23ea34aaa6c754bca35 (diff)
downloadchromium_src-1a84e8ebf01c44c3af3810e62b13b25174cf4e03.zip
chromium_src-1a84e8ebf01c44c3af3810e62b13b25174cf4e03.tar.gz
chromium_src-1a84e8ebf01c44c3af3810e62b13b25174cf4e03.tar.bz2
Report a reasonable error message when test_shell isn't found, and give
some help about what could be wrong. Review URL: http://codereview.chromium.org/7156 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@3373 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--webkit/tools/layout_tests/run_webkit_tests.py14
1 files changed, 11 insertions, 3 deletions
diff --git a/webkit/tools/layout_tests/run_webkit_tests.py b/webkit/tools/layout_tests/run_webkit_tests.py
index f0c669e..b6bffec 100644
--- a/webkit/tools/layout_tests/run_webkit_tests.py
+++ b/webkit/tools/layout_tests/run_webkit_tests.py
@@ -498,11 +498,19 @@ def main(options, args):
options.results_directory = path_utils.GetAbsolutePath(
os.path.join(basedir, options.results_directory))
+ try:
+ test_shell_binary_path = path_utils.TestShellBinaryPath(options.target)
+ except:
+ print "\nERROR: test_shell is not found. Be sure that you have built it and"
+ print "that you are using the correct build. This script will run the"
+ print "release one by default. Use --debug to use the debug build.\n"
+ sys.exit(1)
+
logging.info("Using expected results from %s" %
path_utils.CustomExpectedResultsDir(options.build_type))
logging.info("Placing test results in %s" % options.results_directory)
- logging.info("Using %s build at %s" % (options.target,
- path_utils.TestShellBinaryPath(options.target)))
+ logging.info("Using %s build at %s" %
+ (options.target, test_shell_binary_path))
if options.pixel_tests:
logging.info("Running pixel tests")
@@ -515,7 +523,7 @@ def main(options, args):
sys.exit(1)
# Delete the disk cache if any to ensure a clean test run.
- cachedir = os.path.split(path_utils.TestShellBinaryPath(options.target))[0]
+ cachedir = os.path.split(test_shell_binary_path)[0]
cachedir = os.path.join(cachedir, "cache")
if os.path.exists(cachedir):
shutil.rmtree(cachedir)