Class: Trainer::XCResult::ActionTestableSummary

Inherits:
ActionAbstractTestSummary show all
Defined in:
trainer/lib/trainer/xcresult.rb

Overview

  • ActionTestableSummary

    • Supertype: ActionAbstractTestSummary

    • Kind: object

    • Properties: + projectRelativePath: String? + targetName: String? + testKind: String? + tests: [ActionTestSummaryIdentifiableObject] + diagnosticsDirectoryName: String? + failureSummaries: [ActionTestFailureSummary] + testLanguage: String? + testRegion: String?

Instance Attribute Summary collapse

Attributes inherited from ActionAbstractTestSummary

#name

Attributes inherited from AbstractObject

#type

Instance Method Summary collapse

Methods inherited from AbstractObject

#fetch_value, #fetch_values

Constructor Details

#initialize(data) ⇒ ActionTestableSummary

Returns a new instance of ActionTestableSummary.



79
80
81
82
83
84
85
86
87
# File 'trainer/lib/trainer/xcresult.rb', line 79

def initialize(data)
  self.project_relative_path = fetch_value(data, "projectRelativePath")
  self.target_name = fetch_value(data, "targetName")
  self.test_kind = fetch_value(data, "testKind")
  self.tests = fetch_values(data, "tests").map do |tests_data|
    ActionTestSummaryIdentifiableObject.create(tests_data, self)
  end
  super
end

Instance Attribute Details

#project_relative_pathObject

Returns the value of attribute project_relative_path.



75
76
77
# File 'trainer/lib/trainer/xcresult.rb', line 75

def project_relative_path
  @project_relative_path
end

#target_nameObject

Returns the value of attribute target_name.



76
77
78
# File 'trainer/lib/trainer/xcresult.rb', line 76

def target_name
  @target_name
end

#test_kindObject

Returns the value of attribute test_kind.



77
78
79
# File 'trainer/lib/trainer/xcresult.rb', line 77

def test_kind
  @test_kind
end

#testsObject

Returns the value of attribute tests.



78
79
80
# File 'trainer/lib/trainer/xcresult.rb', line 78

def tests
  @tests
end

Instance Method Details

#all_testsObject



89
90
91
# File 'trainer/lib/trainer/xcresult.rb', line 89

def all_tests
  return tests.map(&:all_subtests).flatten
end