Sha256: 77907efd257ac9a682af4120a7b567c6b263c7ffb3d49158a307e58e944a1d17
Contents?: true
Size: 523 Bytes
Versions: 15
Compression:
Stored size: 523 Bytes
Contents
class Browser def supported?; true; end def setup ; end def open(url) ; end def teardown ; end def host require 'rbconfig' Config::CONFIG['host'] end def macos? host.include?('darwin') end def windows? host.include?('mswin') end def linux? host.include?('linux') end def open(url) case when macos? `open #{url}` when windows? `start #{url}` else puts "I don't know how to open a browser for #{url} on your system" end end end
Version data entries
15 entries across 15 versions & 1 rubygems