Commit 50853f75 authored by ojan@chromium.org's avatar ojan@chromium.org

Unreviewed, rolling out r106302.

http://trac.webkit.org/changeset/106302
https://bugs.webkit.org/show_bug.cgi?id=77472

Broke building DRT before running the tests (Requested by ojan
on #webkit).

Patch by Sheriff Bot <webkit.review.bot@gmail.com> on 2012-01-31

* Scripts/webkit-build-directory:
* Scripts/webkitpy/layout_tests/port/config.py:
(Config.build_directory):
* Scripts/webkitpy/layout_tests/port/config_standalone.py:
(main):
* Scripts/webkitpy/layout_tests/port/config_unittest.py:
(ConfigTest.assert_configuration):
(ConfigTest.test_build_directory.mock_webkit_build_directory):
(ConfigTest.test_build_directory):
(ConfigTest.test_default_configuration__notfound):
* Scripts/webkitpy/layout_tests/port/webkit.py:
(WebKitPort._build_path):

git-svn-id: http://svn.webkit.org/repository/webkit/trunk@106389 268f45cc-cd09-0410-ab3c-d52691b4dbfc
parent 5687a0fe
2012-01-31 Sheriff Bot <webkit.review.bot@gmail.com>
Unreviewed, rolling out r106302.
http://trac.webkit.org/changeset/106302
https://bugs.webkit.org/show_bug.cgi?id=77472
Broke building DRT before running the tests (Requested by ojan
on #webkit).
* Scripts/webkit-build-directory:
* Scripts/webkitpy/layout_tests/port/config.py:
(Config.build_directory):
* Scripts/webkitpy/layout_tests/port/config_standalone.py:
(main):
* Scripts/webkitpy/layout_tests/port/config_unittest.py:
(ConfigTest.assert_configuration):
(ConfigTest.test_build_directory.mock_webkit_build_directory):
(ConfigTest.test_build_directory):
(ConfigTest.test_default_configuration__notfound):
* Scripts/webkitpy/layout_tests/port/webkit.py:
(WebKitPort._build_path):
2012-01-31 Antoine Labour <piman@chromium.org>
Merge WebGraphicsContext3D creation and initialization, and move it to
......@@ -57,15 +57,12 @@ my $getOptionsResult = GetOptions(
'help|h' => \$showHelp,
);
if (!$getOptionsResult || $showHelp) {
if (!$getOptionsResult || $showHelp || (!$showConfigurationDirectory && !$showTopLevelDirectory)) {
print STDERR $usage;
exit 1;
}
if (!$showConfigurationDirectory && !$showTopLevelDirectory) {
print baseProductDir() . "\n";
print productDir() . "\n";
} elsif ($showTopLevelDirectory) {
if ($showTopLevelDirectory) {
print baseProductDir() . "\n";
} else {
print productDir() . "\n";
......
......@@ -74,19 +74,12 @@ class Config(object):
flags = ["--configuration", self.flag_for_configuration(configuration)]
else:
configuration = ""
flags = []
flags = ["--top-level"]
if not self._build_directories.get(configuration):
args = ["perl", self.script_path("webkit-build-directory")] + flags
output = self._executive.run_command(args, cwd=self.webkit_base_dir()).rstrip()
parts = output.split("\n")
self._build_directories[configuration] = parts[0]
if len(parts) == 2:
default_configuration = parts[1][len(parts[0]):]
if default_configuration.startswith("/"):
default_configuration = default_configuration[1:]
self._build_directories[default_configuration] = parts[1]
self._build_directories[configuration] = (
self._executive.run_command(args, cwd=self.webkit_base_dir()).rstrip())
return self._build_directories[configuration]
......
......@@ -57,7 +57,7 @@ def main(argv=None):
argv = sys.argv
if len(argv) == 3 and argv[1] == '--mock':
e = executive_mock.MockExecutive2(output='foo\nfoo/%s' % argv[2])
e = executive_mock.MockExecutive2(output='foo')
fs = filesystem_mock.MockFileSystem({'foo/Configuration': argv[2]})
else:
e = executive.Executive()
......
......@@ -51,21 +51,18 @@ class ConfigTest(unittest.TestCase):
def assert_configuration(self, contents, expected):
# This tests that a configuration file containing
# _contents_ ends up being interpreted as _expected_.
output = 'foo\nfoo/%s' % contents
c = self.make_config(output, {'foo/Configuration': contents})
c = self.make_config('foo', {'foo/Configuration': contents})
self.assertEqual(c.default_configuration(), expected)
def test_build_directory(self):
# --top-level
def mock_webkit_build_directory(arg_list):
if arg_list == ['--top-level']:
return '/WebKitBuild/'
return '/WebKitBuild'
elif arg_list == ['--configuration', '--debug']:
return '/WebKitBuild/Debug'
elif arg_list == ['--configuration', '--release']:
return '/WebKitBuild/Release'
elif arg_list == []:
return '/WebKitBuild/\n/WebKitBuild//Debug\n'
return 'Error'
def mock_run_command(arg_list):
......@@ -74,10 +71,10 @@ class ConfigTest(unittest.TestCase):
return 'Error'
c = self.make_config(run_command_fn=mock_run_command)
self.assertEqual(c.build_directory(None), '/WebKitBuild/')
self.assertTrue(c.build_directory(None).endswith('WebKitBuild'))
# Test again to check caching
self.assertEqual(c.build_directory(None), '/WebKitBuild/')
self.assertTrue(c.build_directory(None).endswith('WebKitBuild'))
# Test other values
self.assertTrue(c.build_directory('Release').endswith('/Release'))
......@@ -98,7 +95,7 @@ class ConfigTest(unittest.TestCase):
def test_default_configuration__notfound(self):
# This tests what happens if the default configuration file doesn't exist.
c = self.make_config(output='foo\nfoo/Release', files={'foo/Configuration': None})
c = self.make_config(output='foo', files={'foo/Configuration': None})
self.assertEqual(c.default_configuration(), "Release")
def test_default_configuration__unknown(self):
......
......@@ -380,9 +380,6 @@ class WebKitPort(Port):
build_directory = self.get_option('root')
if not build_directory:
build_directory = self._config.build_directory(self.get_option('configuration'))
# Set --root here Since this modifies the options object used by the worker subprocesses,
# it avoids the slow call out to build_directory in each subprocess.
self.set_option_default('root', build_directory)
return self._filesystem.join(build_directory, *comps)
def _path_to_driver(self):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment