$LOAD_PATH << File.join(File.dirname(__FILE__), "..", "lib") require 'mongrel' require 'yaml' require 'zlib' class SimpleHandler < Mongrel::HttpHandler def process(request, response) response.start do |head,out| head["Content-Type"] = "text/html" results = "
Your request:#{request.params.to_yaml}View the files." out << results end end end class DumbHandler < Mongrel::HttpHandler def process(request, response) response.start do |head,out| head["Content-Type"] = "text/html" out.write("test") end end end if ARGV.length != 3 STDERR.puts "usage: simpletest.rb