Class: XCTasks::TestTask::Destination

Inherits:
Object
  • Object
show all
Defined in:
lib/xctasks/test_task.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(options = {}) ⇒ Destination

Returns a new instance of Destination.



69
70
71
# File 'lib/xctasks/test_task.rb', line 69

def initialize(options = {})
  options.each { |k,v| self[k] = v }
end

Instance Attribute Details

#archObject

OS X attributes



61
62
63
# File 'lib/xctasks/test_task.rb', line 61

def arch
  @arch
end

#idObject

iOS keys



64
65
66
# File 'lib/xctasks/test_task.rb', line 64

def id
  @id
end

#nameObject

Common Keys



58
59
60
# File 'lib/xctasks/test_task.rb', line 58

def name
  @name
end

#osObject

iOS Simulator keys



67
68
69
# File 'lib/xctasks/test_task.rb', line 67

def os
  @os
end

#platformObject

Common Keys



58
59
60
# File 'lib/xctasks/test_task.rb', line 58

def platform
  @platform
end

Instance Method Details

#[](key) ⇒ Object



80
81
82
# File 'lib/xctasks/test_task.rb', line 80

def [](key)
  send(key)
end

#[]=(key, value) ⇒ Object



84
85
86
# File 'lib/xctasks/test_task.rb', line 84

def []=(key, value)
  send("#{key}=", value)
end

#to_sObject



88
89
90
91
# File 'lib/xctasks/test_task.rb', line 88

def to_s
  keys = [:platform, :name, :arch, :id, :os].reject { |k| self[k].nil? }
  keys.map { |k| "#{key_name(k)}='#{self[k].to_s}'" }.join(',')
end