Class: GroundControl::BuildReport

Inherits:
Object
  • Object
show all
Defined in:
lib/groundcontrol/build_report.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(project_name, branch, testunit_success, cucumber_success, commit) ⇒ BuildReport

Returns a new instance of BuildReport.



8
9
10
11
12
13
14
15
# File 'lib/groundcontrol/build_report.rb', line 8

def initialize(project_name, branch, testunit_success, cucumber_success, commit)
  @project_name = project_name
  @branch = branch
  @testunit_success = testunit_success
  @cucumber_success = cucumber_success
  @commit = commit
  @test_results = []
end

Instance Attribute Details

#branchObject (readonly)

Returns the value of attribute branch.



5
6
7
# File 'lib/groundcontrol/build_report.rb', line 5

def branch
  @branch
end

#commitObject (readonly)

Returns the value of attribute commit.



5
6
7
# File 'lib/groundcontrol/build_report.rb', line 5

def commit
  @commit
end

#cucumber_successObject (readonly)

Returns the value of attribute cucumber_success.



5
6
7
# File 'lib/groundcontrol/build_report.rb', line 5

def cucumber_success
  @cucumber_success
end

#project_nameObject (readonly)

Returns the value of attribute project_name.



5
6
7
# File 'lib/groundcontrol/build_report.rb', line 5

def project_name
  @project_name
end

#test_resultsObject

Returns the value of attribute test_results.



6
7
8
# File 'lib/groundcontrol/build_report.rb', line 6

def test_results
  @test_results
end

#testunit_successObject (readonly)

Returns the value of attribute testunit_success.



5
6
7
# File 'lib/groundcontrol/build_report.rb', line 5

def testunit_success
  @testunit_success
end

Instance Method Details

#failed?Boolean

Returns:

  • (Boolean)


21
22
23
# File 'lib/groundcontrol/build_report.rb', line 21

def failed?
  !success?
end

#success?Boolean

Returns:

  • (Boolean)


17
18
19
# File 'lib/groundcontrol/build_report.rb', line 17

def success?
  testunit_success && cucumber_success
end