run-webkit-tests fails due to simulator devices from previous SDK installs being marked as unavailable: RuntimeError raised: Expected an iOS Simulator device line, got "-- Unavailable: com.apple.CoreSimulator.SimRuntime.iOS-8-0 --" Traceback (most recent call last): File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py", line 80, in main run_details = run(port, options, args, stderr) File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py", line 417, in run _set_up_derived_options(port, options) File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/layout_tests/run_webkit_tests.py", line 397, in _set_up_derived_options options.runtime = xcode.simulator.Simulator().latest_available_runtime File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/xcode/simulator.py", line 229, in __init__ self.refresh() File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/xcode/simulator.py", line 246, in refresh self._parse_device_types(lines) File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/xcode/simulator.py", line 265, in _parse_device_types self._parse_runtimes(lines) File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/xcode/simulator.py", line 286, in _parse_runtimes self._parse_devices(lines) File "/Volumes/Data/WebKit.git/Tools/Scripts/webkitpy/xcode/simulator.py", line 305, in _parse_devices raise RuntimeError('Expected an iOS Simulator device line, got "{}"'.format(line)) RuntimeError: Expected an iOS Simulator device line, got "-- Unavailable: com.apple.CoreSimulator.SimRuntime.iOS-8-0 --"
<rdar://problem/19636406>
Created attachment 246227 [details] Patch v1
Comment on attachment 246227 [details] Patch v1 This patch is OK as-is. As remarked in a comment above class Simulator in this file, we may want consider parsing the device.plist files instead of parsing the simctl output, which seems more likely to change.
Comment on attachment 246227 [details] Patch v1 View in context: https://bugs.webkit.org/attachment.cgi?id=246227&action=review > Tools/Scripts/webkitpy/xcode/simulator_unittest.py:230 > + self.assertEqual('com.apple.CoreSimulator.SimRuntime.iOS-8-0', runtime_ios_8.identifier) > + self.assertEqual(True, runtime_ios_8.available) > + self.assertEqual(False, runtime_ios_8.is_internal_runtime) > + self.assertEqual(tuple([8, 0]), runtime_ios_8.version) > + self.assertEqual(1, len(runtime_ios_8.devices)) I wish there was a better way to write this. One idea is to take advantage of Runtime's equality operator __eq__, construct a expected Runtime object and then perform self.assertEqual(expected_runtime, runtime_ios_8). We may want to add logic to Runtime.__eq__ to support checking the Runtime.is_internal_runtime, or even Runtime.available.
Comment on attachment 246227 [details] Patch v1 Clearing flags on attachment: 246227 Committed r179793: <http://trac.webkit.org/changeset/179793>
All reviewed patches have been landed. Closing bug.