Class: RubyCritic::Browser

Inherits:
Object
  • Object
show all
Defined in:
lib/rubycritic/browser.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(report_path) ⇒ Browser

Returns a new instance of Browser.



9
10
11
# File 'lib/rubycritic/browser.rb', line 9

def initialize(report_path)
  @report_path = report_path
end

Instance Attribute Details

#report_pathObject (readonly)

Returns the value of attribute report_path.



7
8
9
# File 'lib/rubycritic/browser.rb', line 7

def report_path
  @report_path
end

Instance Method Details

#openObject



13
14
15
16
17
# File 'lib/rubycritic/browser.rb', line 13

def open
  Launchy.open(report_path) do |exception|
    puts "Attempted to open #{report_path} and failed because #{exception}"
  end
end