Choose test server port reliably

Specify :Port => 0 for WEBrick::HTTPServer.new and
obtain the port actually bound.
Merge pull request #706 from akr/choose_port_reliably

Choose test server port reliably