Class: FaHarnessTools::HarnessContext

Inherits:
Object
  • Object
show all
Defined in:
lib/fa-harness-tools/harness_context.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(client:, environment:, build_no:) ⇒ HarnessContext



5
6
7
8
9
# File 'lib/fa-harness-tools/harness_context.rb', line 5

def initialize(client:, environment:, build_no:)
  @client = client
  @environment = environment
  @build_no = build_no
end

Instance Attribute Details

#environmentObject (readonly)

Returns the value of attribute environment.



3
4
5
# File 'lib/fa-harness-tools/harness_context.rb', line 3

def environment
  @environment
end

Instance Method Details

#new_commit_shaObject



11
12
13
# File 'lib/fa-harness-tools/harness_context.rb', line 11

def new_commit_sha
  @new_commit_sha ||= @client.get_commit_sha(@build_no)
end