ruby-changes:25602
From: usa <ko1@a...>
Date: Thu, 15 Nov 2012 15:15:26 +0900 (JST)
Subject: [ruby-changes:25602] usa:r37659 (ruby_1_9_3): merge revision(s) 36491,36877: [Backport #7320]
usa 2012-11-15 15:15:17 +0900 (Thu, 15 Nov 2012) New Revision: 37659 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=37659 Log: merge revision(s) 36491,36877: [Backport #7320] Use 0 for webrick's port and get the actual port. [Bug #6766] Modified directories: branches/ruby_1_9_3/ Modified files: branches/ruby_1_9_3/test/net/http/test_http.rb branches/ruby_1_9_3/test/net/http/test_https.rb branches/ruby_1_9_3/test/net/http/utils.rb branches/ruby_1_9_3/version.h Index: ruby_1_9_3/version.h =================================================================== --- ruby_1_9_3/version.h (revision 37658) +++ ruby_1_9_3/version.h (revision 37659) @@ -1,10 +1,10 @@ #define RUBY_VERSION "1.9.3" -#define RUBY_PATCHLEVEL 330 +#define RUBY_PATCHLEVEL 331 -#define RUBY_RELEASE_DATE "2012-11-14" +#define RUBY_RELEASE_DATE "2012-11-15" #define RUBY_RELEASE_YEAR 2012 #define RUBY_RELEASE_MONTH 11 -#define RUBY_RELEASE_DAY 14 +#define RUBY_RELEASE_DAY 15 #include "ruby/version.h" Index: ruby_1_9_3/test/net/http/test_http.rb =================================================================== --- ruby_1_9_3/test/net/http/test_http.rb (revision 37658) +++ ruby_1_9_3/test/net/http/test_http.rb (revision 37659) @@ -426,7 +426,7 @@ class TestNetHTTP_v1_2 < Test::Unit::TestCase CONFIG = { 'host' => '127.0.0.1', - 'port' => 10081, + 'port' => 0, 'proxy_host' => nil, 'proxy_port' => nil, } @@ -444,7 +444,7 @@ class TestNetHTTP_v1_2_chunked < Test::Unit::TestCase CONFIG = { 'host' => '127.0.0.1', - 'port' => 10081, + 'port' => 0, 'proxy_host' => nil, 'proxy_port' => nil, 'chunked' => true, @@ -476,7 +476,7 @@ class TestNetHTTPContinue < Test::Unit::TestCase CONFIG = { 'host' => '127.0.0.1', - 'port' => 10081, + 'port' => 0, 'proxy_host' => nil, 'proxy_port' => nil, 'chunked' => true, Index: ruby_1_9_3/test/net/http/utils.rb =================================================================== --- ruby_1_9_3/test/net/http/utils.rb (revision 37658) +++ ruby_1_9_3/test/net/http/utils.rb (revision 37659) @@ -19,7 +19,8 @@ end def config(key) - self.class::CONFIG[key] + @config ||= self.class::CONFIG + @config[key] end def logfile @@ -42,6 +43,7 @@ end def spawn_server + @config = self.class::CONFIG server_config = { :BindAddress => config('host'), :Port => config('port'), @@ -61,6 +63,7 @@ @server = WEBrick::HTTPServer.new(server_config) @server.mount('/', Servlet, config('chunked')) @server.start + @config['port'] = @server[:Port] if @config['port'] == 0 n_try_max = 5 begin TCPSocket.open(config('host'), config('port')).close Index: ruby_1_9_3/test/net/http/test_https.rb =================================================================== --- ruby_1_9_3/test/net/http/test_https.rb (revision 37658) +++ ruby_1_9_3/test/net/http/test_https.rb (revision 37659) @@ -24,7 +24,7 @@ CONFIG = { 'host' => '127.0.0.1', - 'port' => 10082, # different from test_http.rb + 'port' => 0, 'proxy_host' => nil, 'proxy_port' => nil, 'ssl_enable' => true, Property changes on: ruby_1_9_3 ___________________________________________________________________ Modified: svn:mergeinfo Merged /trunk:r36491,36877 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/