| OLD | NEW |
| 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 1141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1152 self._websocket_server.stop() | 1152 self._websocket_server.stop() |
| 1153 self._websocket_server = None | 1153 self._websocket_server = None |
| 1154 | 1154 |
| 1155 # | 1155 # |
| 1156 # TEST EXPECTATION-RELATED METHODS | 1156 # TEST EXPECTATION-RELATED METHODS |
| 1157 # | 1157 # |
| 1158 | 1158 |
| 1159 def test_configuration(self): | 1159 def test_configuration(self): |
| 1160 """Returns the current TestConfiguration for the port.""" | 1160 """Returns the current TestConfiguration for the port.""" |
| 1161 if not self._test_configuration: | 1161 if not self._test_configuration: |
| 1162 self._test_configuration = TestConfiguration(self._version, self._ar
chitecture, self._options.configuration.lower()) | 1162 gn_args = self._executive.run_command([ |
| 1163 'gn', 'args', |
| 1164 self._build_path_with_configuration(self._options.configuration)
, |
| 1165 '--list', '--short']) |
| 1166 |
| 1167 if 'is_debug = true' in gn_args: |
| 1168 configuration = 'debug' |
| 1169 else: |
| 1170 configuration = 'release' |
| 1171 |
| 1172 self._test_configuration = TestConfiguration(self._version, self._ar
chitecture, configuration) |
| 1163 return self._test_configuration | 1173 return self._test_configuration |
| 1164 | 1174 |
| 1165 # FIXME: Belongs on a Platform object. | 1175 # FIXME: Belongs on a Platform object. |
| 1166 @memoized | 1176 @memoized |
| 1167 def all_test_configurations(self): | 1177 def all_test_configurations(self): |
| 1168 """Returns a list of TestConfiguration instances, representing all avail
able | 1178 """Returns a list of TestConfiguration instances, representing all avail
able |
| 1169 test configurations for this port.""" | 1179 test configurations for this port.""" |
| 1170 return self._generate_all_test_configurations() | 1180 return self._generate_all_test_configurations() |
| 1171 | 1181 |
| 1172 # FIXME: Belongs on a Platform object. | 1182 # FIXME: Belongs on a Platform object. |
| (...skipping 592 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1765 | 1775 |
| 1766 class PhysicalTestSuite(object): | 1776 class PhysicalTestSuite(object): |
| 1767 def __init__(self, base, args): | 1777 def __init__(self, base, args): |
| 1768 self.name = base | 1778 self.name = base |
| 1769 self.base = base | 1779 self.base = base |
| 1770 self.args = args | 1780 self.args = args |
| 1771 self.tests = set() | 1781 self.tests = set() |
| 1772 | 1782 |
| 1773 def __repr__(self): | 1783 def __repr__(self): |
| 1774 return "PhysicalTestSuite('%s', '%s', %s)" % (self.name, self.base, self
.args) | 1784 return "PhysicalTestSuite('%s', '%s', %s)" % (self.name, self.base, self
.args) |
| OLD | NEW |