From 95d050e357cd2f2a226621dd8639baaf30cad544 Mon Sep 17 00:00:00 2001 From: "mattm@chromium.org" Date: Thu, 10 Sep 2009 19:30:46 +0000 Subject: Hack to make tests work if out is a symlink: see if the current dir is the source root. Fix some tests that were manually getting sourcedir from DIR_EXE instead of using DIR_SOURCE_ROOT. BUG=none TEST=rm -r out, ln -s /somedir/out out, run tests Review URL: http://codereview.chromium.org/192064 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@25898 0039d316-1c4b-4281-b951-d872f2087c98 --- webkit/tools/test_shell/test_shell_gtk.cc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'webkit') diff --git a/webkit/tools/test_shell/test_shell_gtk.cc b/webkit/tools/test_shell/test_shell_gtk.cc index 72864e2..87e80a5 100644 --- a/webkit/tools/test_shell/test_shell_gtk.cc +++ b/webkit/tools/test_shell/test_shell_gtk.cc @@ -612,8 +612,8 @@ std::string TestShell::RewriteLocalUrl(const std::string& url) { std::string new_url(url); if (url.compare(0, kPrefixLen, kPrefix, kPrefixLen) == 0) { FilePath replace_path; - PathService::Get(base::DIR_EXE, &replace_path); - replace_path = replace_path.DirName().DirName().Append( + PathService::Get(base::DIR_SOURCE_ROOT, &replace_path); + replace_path = replace_path.Append( "webkit/data/layout_tests/LayoutTests/"); new_url = std::string("file://") + replace_path.value() + url.substr(kPrefixLen); -- cgit v1.1