lib/simctl/command/io.rb in simctl-1.5.8 vs lib/simctl/command/io.rb in simctl-1.6.0
- old
+ new
@@ -10,10 +10,10 @@
# @param opts Optional hash that supports two keys:
# * type: Can be png, tiff, bmp, gif, jpeg (default is png)
# * display: Can be main or tv for iOS, tv for tvOS and main for watchOS
# @return [void]
def screenshot(device, file, opts={})
- unless XcodeVersion.gte? '8.2'
+ unless Xcode::Version.gte? '8.2'
raise UnsupportedCommandError.new('Needs at least Xcode 8.2')
end
optional_args = opts.map {|k,v| "--#{k}=#{Shellwords.shellescape(v)}"}
Executor.execute(command_for('io', device.udid, 'screenshot', *optional_args, Shellwords.shellescape(file)))
end