Sha256: f67412883cc797071d53e4eba851e3d4980ab7161e9396f221a892f2958bbc9a
Contents?: true
Size: 392 Bytes
Versions: 31
Compression:
Stored size: 392 Bytes
Contents
require 'webrick' class ::WEBrick::BasicLog def log(level, data) # nop end end port = 8000 webserver = Thread.new do WEBrick::HTTPServer.new( :Port => port, :DocumentRoot => "#{Dir.pwd}/test/sample_data", Logger: WEBrick::Log.new("/dev/null"), AccessLog: [] ).start end puts "staring webserver on port #{port}" webserver.run at_exit { Thread.kill webserver }
Version data entries
31 entries across 31 versions & 1 rubygems