Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(598)

Side by Side Diff: third_party/WebKit/Tools/Scripts/webkitpy/layout_tests/port/mac.py

Issue 2725133005: Add 10.12 as a supported version in MacPort. (Closed)
Patch Set: Created 3 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 # Copyright (C) 2010 Google Inc. All rights reserved. 1 # Copyright (C) 2010 Google Inc. All rights reserved.
2 # 2 #
3 # Redistribution and use in source and binary forms, with or without 3 # Redistribution and use in source and binary forms, with or without
4 # modification, are permitted provided that the following conditions are 4 # modification, are permitted provided that the following conditions are
5 # met: 5 # met:
6 # 6 #
7 # * Redistributions of source code must retain the above copyright 7 # * Redistributions of source code must retain the above copyright
8 # notice, this list of conditions and the following disclaimer. 8 # notice, this list of conditions and the following disclaimer.
9 # * Redistributions in binary form must reproduce the above 9 # * Redistributions in binary form must reproduce the above
10 # copyright notice, this list of conditions and the following disclaimer 10 # copyright notice, this list of conditions and the following disclaimer
(...skipping 19 matching lines...) Expand all
30 30
31 import logging 31 import logging
32 32
33 from webkitpy.layout_tests.port import base 33 from webkitpy.layout_tests.port import base
34 34
35 35
36 _log = logging.getLogger(__name__) 36 _log = logging.getLogger(__name__)
37 37
38 38
39 class MacPort(base.Port): 39 class MacPort(base.Port):
40 SUPPORTED_VERSIONS = ('mac10.9', 'mac10.10', 'mac10.11', 'retina') 40 SUPPORTED_VERSIONS = ('mac10.9', 'mac10.10', 'mac10.11', 'mac10.12', 'retina ')
41 port_name = 'mac' 41 port_name = 'mac'
42 42
43 # FIXME: We treat Retina (High-DPI) devices as if they are running 43 # FIXME: We treat Retina (High-DPI) devices as if they are running
44 # a different operating system version. This is lame and should be fixed. 44 # a different operating system version. This is lame and should be fixed.
45 # Note that the retina versions fallback to the non-retina versions and so n o 45 # Note that the retina versions fallback to the non-retina versions and so n o
46 # baselines are shared between retina versions; this keeps the fallback grap h as a tree 46 # baselines are shared between retina versions; this keeps the fallback grap h as a tree
47 # and maximizes the number of baselines we can share that way. 47 # and maximizes the number of baselines we can share that way.
48 # We also currently only support Retina on 10.11. 48 # We also currently only support Retina on 10.11.
49 49
50 FALLBACK_PATHS = {} 50 FALLBACK_PATHS = {}
51 FALLBACK_PATHS['mac10.11'] = ['mac'] 51 FALLBACK_PATHS['mac10.12'] = ['mac']
52 FALLBACK_PATHS['mac10.11'] = ['mac-mac10.11'] + FALLBACK_PATHS['mac10.12']
52 FALLBACK_PATHS['mac10.10'] = ['mac-mac10.10'] + FALLBACK_PATHS['mac10.11'] 53 FALLBACK_PATHS['mac10.10'] = ['mac-mac10.10'] + FALLBACK_PATHS['mac10.11']
53 FALLBACK_PATHS['mac10.9'] = ['mac-mac10.9'] + FALLBACK_PATHS['mac10.10'] 54 FALLBACK_PATHS['mac10.9'] = ['mac-mac10.9'] + FALLBACK_PATHS['mac10.10']
54 FALLBACK_PATHS['retina'] = ['mac-retina', 'mac'] 55 FALLBACK_PATHS['retina'] = ['mac-retina', 'mac']
55 56
56 DEFAULT_BUILD_DIRECTORIES = ('xcodebuild', 'out') 57 DEFAULT_BUILD_DIRECTORIES = ('xcodebuild', 'out')
57 58
58 CONTENT_SHELL_NAME = 'Content Shell' 59 CONTENT_SHELL_NAME = 'Content Shell'
59 60
60 BUILD_REQUIREMENTS_URL = 'https://chromium.googlesource.com/chromium/src/+/m aster/docs/mac_build_instructions.md' 61 BUILD_REQUIREMENTS_URL = 'https://chromium.googlesource.com/chromium/src/+/m aster/docs/mac_build_instructions.md'
61 62
62 @classmethod 63 @classmethod
63 def determine_full_port_name(cls, host, options, port_name): 64 def determine_full_port_name(cls, host, options, port_name):
64 if port_name.endswith('mac'): 65 if port_name.endswith('mac'):
65 if host.platform.os_version in ('future',): 66 version = host.platform.os_version
66 version = 'mac10.11'
67 else:
68 version = host.platform.os_version
69 if host.platform.is_highdpi(): 67 if host.platform.is_highdpi():
70 version = 'retina' 68 version = 'retina'
71 return port_name + '-' + version 69 return port_name + '-' + version
72 return port_name 70 return port_name
73 71
74 def __init__(self, host, port_name, **kwargs): 72 def __init__(self, host, port_name, **kwargs):
75 super(MacPort, self).__init__(host, port_name, **kwargs) 73 super(MacPort, self).__init__(host, port_name, **kwargs)
76 self._version = port_name[port_name.index('mac-') + len('mac-'):] 74 self._version = port_name[port_name.index('mac-') + len('mac-'):]
77 assert self._version in self.SUPPORTED_VERSIONS 75 assert self._version in self.SUPPORTED_VERSIONS
78 76
(...skipping 15 matching lines...) Expand all
94 92
95 def path_to_apache(self): 93 def path_to_apache(self):
96 return '/usr/sbin/httpd' 94 return '/usr/sbin/httpd'
97 95
98 def path_to_apache_config_file(self): 96 def path_to_apache_config_file(self):
99 config_file_name = 'apache2-httpd-' + self._apache_version() + '.conf' 97 config_file_name = 'apache2-httpd-' + self._apache_version() + '.conf'
100 return self._filesystem.join(self.apache_config_directory(), config_file _name) 98 return self._filesystem.join(self.apache_config_directory(), config_file _name)
101 99
102 def _path_to_driver(self, target=None): 100 def _path_to_driver(self, target=None):
103 return self._build_path_with_target(target, self.driver_name() + '.app', 'Contents', 'MacOS', self.driver_name()) 101 return self._build_path_with_target(target, self.driver_name() + '.app', 'Contents', 'MacOS', self.driver_name())
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698