Method: RunLoop::Ipa#initialize

Defined in:
lib/run_loop/ipa.rb

#initialize(path_to_ipa) ⇒ Calabash::Ipa

Create a new ipa instance.

Parameters:

  • path_to_ipa (String)

    The path the .ipa file.

Raises:

  • (RuntimeError)

    If the file does not exist.

  • (RuntimeError)

    If the file does not end in .ipa.



15
16
17
18
19
20
21
22
23
24
# File 'lib/run_loop/ipa.rb', line 15

def initialize(path_to_ipa)
  unless File.exist? path_to_ipa
    raise "Expected an ipa at '#{path_to_ipa}'"
  end

  unless path_to_ipa.end_with?('.ipa')
    raise "Expected '#{path_to_ipa}' to be an .ipa"
  end
  @path = path_to_ipa
end