Diff
Modified: trunk/Tools/ChangeLog (92881 => 92882)
--- trunk/Tools/ChangeLog 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/ChangeLog 2011-08-11 21:59:11 UTC (rev 92882)
@@ -1,3 +1,24 @@
+2011-08-11 Eric Seidel <[email protected]>
+
+ NRWT has wrong fallback order for Mac now that Lion exists
+ https://bugs.webkit.org/show_bug.cgi?id=66093
+
+ Reviewed by Adam Barth.
+
+ ORWT used a different system for fallback orders than NRWT did.
+ I moved win.py to match ORWT fallback orders in bug 64486.
+ This bug moves mac.py to match ORWT fallback order
+ and adds 'lion' as a supported OS version.
+
+ Because ChromiumMac shares OS version detection code with AppleMac
+ this also added support for 'lion' to chromium mac. Hopefully that's a good thing.
+
+ * Scripts/webkitpy/layout_tests/port/chromium_mac.py:
+ * Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py:
+ * Scripts/webkitpy/layout_tests/port/mac.py:
+ * Scripts/webkitpy/layout_tests/port/mac_unittest.py:
+ * Scripts/webkitpy/layout_tests/port/win.py:
+
2011-08-11 Adam Barth <[email protected]>
Update test results now that we use absolute URLs.
Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac.py (92881 => 92882)
--- trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac.py 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac.py 2011-08-11 21:59:11 UTC (rev 92882)
@@ -43,8 +43,7 @@
class ChromiumMacPort(chromium.ChromiumPort):
- """Chromium Mac implementation of the Port class."""
- SUPPORTED_OS_VERSIONS = ('leopard', 'snowleopard', 'future')
+ SUPPORTED_OS_VERSIONS = ('leopard', 'snowleopard', 'lion', 'future')
FALLBACK_PATHS = {
'leopard': [
Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py (92881 => 92882)
--- trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/chromium_mac_unittest.py 2011-08-11 21:59:11 UTC (rev 92882)
@@ -63,10 +63,10 @@
self.assert_name('chromium-mac-snowleopard', '10.5.3', 'chromium-mac-snowleopard')
self.assert_name('chromium-mac-snowleopard', '10.6.3', 'chromium-mac-snowleopard')
- self.assert_name(None, '10.7', 'chromium-mac-future')
- self.assert_name(None, '10.7.3', 'chromium-mac-future')
+ self.assert_name(None, '10.7', 'chromium-mac-lion')
+ self.assert_name(None, '10.7.3', 'chromium-mac-lion')
self.assert_name(None, '10.8', 'chromium-mac-future')
- self.assert_name('chromium-mac', '10.7.3', 'chromium-mac-future')
+ self.assert_name('chromium-mac', '10.7.3', 'chromium-mac-lion')
self.assert_name('chromium-mac-future', '10.4.3', 'chromium-mac-future')
self.assert_name('chromium-mac-future', '10.5.3', 'chromium-mac-future')
self.assert_name('chromium-mac-future', '10.6.3', 'chromium-mac-future')
Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/mac.py (92881 => 92882)
--- trunk/Tools/Scripts/webkitpy/layout_tests/port/mac.py 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/mac.py 2011-08-11 21:59:11 UTC (rev 92882)
@@ -161,7 +161,7 @@
version_strings = {
5: 'leopard',
6: 'snowleopard',
- # Add 7: 'lion' here?
+ 7: 'lion',
}
assert release_version >= min(version_strings.keys())
version_string = version_strings.get(release_version, 'future')
@@ -173,36 +173,26 @@
class MacPort(WebKitPort):
port_name = "mac"
- # FIXME: 'wk2' probably shouldn't be a version, it should probably be
- # a modifier, like 'chromium-gpu' is to 'chromium'.
- SUPPORTED_VERSIONS = ('leopard', 'snowleopard', 'future', 'wk2')
+ # This is a list of all supported OS-VERSION pairs for the AppleMac port
+ # and the order of fallback between them. Matches ORWT.
+ VERSION_FALLBACK_ORDER = ["mac-leopard", "mac-snowleopard", "mac-lion", "mac"]
- FALLBACK_PATHS = {
- 'leopard': [
- 'mac-leopard',
- 'mac-snowleopard',
- 'mac',
- ],
- 'snowleopard': [
- 'mac-snowleopard',
- 'mac',
- ],
- 'future': [
- 'mac',
- ],
- 'wk2': [], # wk2 does not make sense as a version, this is only here to make the rebaseline unit tests not crash.
- }
-
def __init__(self, port_name=None, os_version_string=None, **kwargs):
port_name = port_name or 'mac'
WebKitPort.__init__(self, port_name=port_name, **kwargs)
+
+ # FIXME: This sort of parsing belongs in factory.py!
+ if port_name == 'mac-wk2':
+ port_name = 'mac'
+ # FIXME: This may be wrong, since options is a global property, and the port_name is specific to this object?
+ self.set_option_default('webkit_test_runner', True)
+
if port_name == 'mac':
self._version = os_version(os_version_string)
self._name = port_name + '-' + self._version
else:
- assert port_name.startswith('mac')
+ assert port_name in self.VERSION_FALLBACK_ORDER, "%s is not in %s" % (port_name, self.VERSION_FALLBACK_ORDER)
self._version = port_name[len('mac-'):]
- assert self._version in self.SUPPORTED_VERSIONS, "%s is not in %s" % (self._version, self.SUPPORTED_VERSIONS)
self._operating_system = 'mac'
self._leak_detector = LeakDetector(self)
if self.get_option("leaks"):
@@ -210,11 +200,24 @@
# with MallocStackLogging enabled.
self.set_option_default("batch_size", 1000)
+ # FIXME: A more sophisitcated version of this function should move to WebKitPort and replace all calls to name().
+ def _port_name_with_version(self):
+ components = [self.port_name]
+ if self._version != 'future': # FIXME: This is a hack, but TestConfiguration doesn't like self._version ever being None.
+ components.append(self._version)
+ return '-'.join(components)
+
def baseline_search_path(self):
- search_paths = self.FALLBACK_PATHS[self._version]
+ try:
+ fallback_index = self.VERSION_FALLBACK_ORDER.index(self._port_name_with_version())
+ fallback_names = list(self.VERSION_FALLBACK_ORDER[fallback_index:])
+ except ValueError:
+ # Unknown versions just fall back to the base port results.
+ fallback_names = [self.port_name]
if self.get_option('webkit_test_runner'):
- search_paths.insert(0, self._wk2_port_name())
- return map(self._webkit_baseline_path, search_paths)
+ fallback_names.insert(0, self._wk2_port_name())
+ # Note we do not add 'wk2' here, even though it's included in _skipped_search_paths().
+ return map(self._webkit_baseline_path, fallback_names)
def setup_environ_for_server(self, server_name=None):
env = WebKitPort.setup_environ_for_server(self, server_name)
@@ -239,8 +242,12 @@
def _generate_all_test_configurations(self):
configurations = []
- for version in self.SUPPORTED_VERSIONS:
- for build_type in ('release', 'debug'):
+ for version in self.VERSION_FALLBACK_ORDER:
+ version = version.replace('mac-', '')
+ if version == 'mac': # It's unclear what the "version" for 'mac' is?
+ continue
+ # This method is only used for test_expectations.txt, so shouldn't matter that it's wrong.
+ for build_type in self.ALL_BUILD_TYPES:
configurations.append(TestConfiguration(version=version, architecture='x86', build_type=build_type, graphics_type='cpu'))
return configurations
Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/mac_unittest.py (92881 => 92882)
--- trunk/Tools/Scripts/webkitpy/layout_tests/port/mac_unittest.py 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/mac_unittest.py 2011-08-11 21:59:11 UTC (rev 92882)
@@ -175,7 +175,7 @@
def test_versions(self):
port = self.make_port()
if port:
- self.assertTrue(port.name() in ('mac-leopard', 'mac-snowleopard', 'mac-future'))
+ self.assertTrue(port.name() in ('mac-leopard', 'mac-snowleopard', 'mac-lion'))
self.assert_name(None, '10.5.3', 'mac-leopard')
self.assert_name('mac', '10.5.3', 'mac-leopard')
@@ -189,14 +189,10 @@
self.assert_name('mac-snowleopard', '10.5.3', 'mac-snowleopard')
self.assert_name('mac-snowleopard', '10.6.3', 'mac-snowleopard')
- self.assert_name(None, '10.7', 'mac-future')
- self.assert_name(None, '10.7.3', 'mac-future')
+ self.assert_name(None, '10.7', 'mac-lion')
+ self.assert_name(None, '10.7.3', 'mac-lion')
self.assert_name(None, '10.8', 'mac-future')
- self.assert_name('mac', '10.7.3', 'mac-future')
- self.assert_name('mac-future', '10.4.3', 'mac-future')
- self.assert_name('mac-future', '10.5.3', 'mac-future')
- self.assert_name('mac-future', '10.6.3', 'mac-future')
- self.assert_name('mac-future', '10.7.3', 'mac-future')
+ self.assert_name('mac', '10.7.3', 'mac-lion')
self.assertRaises(AssertionError, self.assert_name, None, '10.3.1', 'should-raise-assertion-so-this-value-does-not-matter')
@@ -210,11 +206,13 @@
def test_baseline_search_path(self):
# FIXME: Is this really right? Should mac-leopard fallback to mac-snowleopard?
- self._assert_search_path(['mac-leopard', 'mac-snowleopard', 'mac'], 'leopard')
- self._assert_search_path(['mac-snowleopard', 'mac'], 'snowleopard')
+ self._assert_search_path(['mac-leopard', 'mac-snowleopard', 'mac-lion', 'mac'], 'leopard')
+ self._assert_search_path(['mac-snowleopard', 'mac-lion', 'mac'], 'snowleopard')
+ self._assert_search_path(['mac-lion', 'mac'], 'lion')
- self._assert_search_path(['mac-wk2', 'mac-leopard', 'mac-snowleopard', 'mac'], 'leopard', use_webkit2=True)
- self._assert_search_path(['mac-wk2', 'mac-snowleopard', 'mac'], 'snowleopard', use_webkit2=True)
+ self._assert_search_path(['mac-wk2', 'mac-leopard', 'mac-snowleopard', 'mac-lion', 'mac'], 'leopard', use_webkit2=True)
+ self._assert_search_path(['mac-wk2', 'mac-snowleopard', 'mac-lion', 'mac'], 'snowleopard', use_webkit2=True)
+ self._assert_search_path(['mac-wk2', 'mac-lion', 'mac'], 'lion', use_webkit2=True)
def test_show_results_html_file(self):
port = MacPort(filesystem=MockFileSystem(), user=MockUser(), executive=MockExecutive())
Modified: trunk/Tools/Scripts/webkitpy/layout_tests/port/win.py (92881 => 92882)
--- trunk/Tools/Scripts/webkitpy/layout_tests/port/win.py 2011-08-11 21:56:04 UTC (rev 92881)
+++ trunk/Tools/Scripts/webkitpy/layout_tests/port/win.py 2011-08-11 21:59:11 UTC (rev 92882)
@@ -99,8 +99,12 @@
def _generate_all_test_configurations(self):
configurations = []
- for build_type in self.ALL_BUILD_TYPES:
- configurations.append(TestConfiguration(version=self._version, architecture='x86', build_type=build_type, graphics_type='cpu'))
+ for version in self.VERSION_FALLBACK_ORDER:
+ version = version.replace('win-', '')
+ if version == 'win': # It's unclear what the "version" for 'win' is?
+ continue
+ for build_type in self.ALL_BUILD_TYPES:
+ configurations.append(TestConfiguration(version=self._version, architecture='x86', build_type=build_type, graphics_type='cpu'))
return configurations
# FIXME: webkitperl/httpd.pm installs /usr/lib/apache/libphp4.dll on cycwin automatically