Class: ShowInfo

Inherits:
Object
  • Object
show all
Defined in:
lib/teuton-get/show_info.rb

Instance Method Summary collapse

Constructor Details

#initializeShowInfo

Returns a new instance of ShowInfo.



8
9
10
# File 'lib/teuton-get/show_info.rb', line 8

def initialize
  @repo_data = RepoData.default
end

Instance Method Details

#call(testid, options) ⇒ Object



12
13
14
15
16
17
18
19
# File 'lib/teuton-get/show_info.rb', line 12

def call(testid, options)
  testinfo = get_testinfo(testid)
  if options["format"] == "json"
    puts testinfo.to_json
  else
    @repo_data.show_testinfo(testinfo)
  end
end