Class: Instrumentality::Simctl
- Inherits:
-
Object
- Object
- Instrumentality::Simctl
- Defined in:
- lib/instrumentality/simctl.rb
Class Method Summary collapse
Class Method Details
.execute_with_simulator_ready(runtime, type) ⇒ Object
6 7 8 9 10 11 12 13 14 15 16 17 18 19 |
# File 'lib/instrumentality/simctl.rb', line 6 def self.execute_with_simulator_ready(runtime, type) device = create_device(runtime, type) device.launch device.wait(Constants::TIMEOUT) do |d| d.state == :booted && d.ready? end begin yield device rescue StandardError => error throw error ensure delete_device(device) end end |