Class: CoPilot::Facade

Inherits:
Object
  • Object
show all
Defined in:
lib/copilot/facade.rb

Instance Method Summary collapse

Constructor Details

#initialize(email_address, password) ⇒ Facade

Returns a new instance of Facade.



7
8
9
10
11
12
# File 'lib/copilot/facade.rb', line 7

def initialize(email_address, password)
  @email_address = email_address
  @password = password
  @browser = Watir::Browser.new
  
end

Instance Method Details

#builds_for_bundle_id(bundle_id, options = {}) ⇒ Object



14
15
16
# File 'lib/copilot/facade.rb', line 14

def builds_for_bundle_id(bundle_id, options={})
  BuildsForBundleIdRequest.new(b).send bundle_id, options
end

#feedback_for_build_id(build_id, options = {}) ⇒ Object



18
19
20
# File 'lib/copilot/facade.rb', line 18

def feedback_for_build_id(build_id, options={})
  FeedbackForBuildIdRequest.new(b).send build_id, options
end

#loginObject



22
23
24
25
26
27
28
# File 'lib/copilot/facade.rb', line 22

def 
  b.goto 'https://www.testflightapp.com/login'
  b.text_field(name: 'username').set @email_address
  b.text_field(name: 'password').set @password
  b.button(value: /Go/).click
   if b.url.start_with? 'https://www.testflightapp.com/login'
end