ruby-changes:17776
From: naruse <ko1@a...>
Date: Mon, 15 Nov 2010 11:37:35 +0900 (JST)
Subject: [ruby-changes:17776] Ruby:r29786 (trunk): Prevent timing failure.
naruse 2010-11-15 11:37:19 +0900 (Mon, 15 Nov 2010) New Revision: 29786 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=29786 Log: Prevent timing failure. Modified files: trunk/test/cgi/test_cgi_header.rb Index: test/cgi/test_cgi_header.rb =================================================================== --- test/cgi/test_cgi_header.rb (revision 29785) +++ test/cgi/test_cgi_header.rb (revision 29786) @@ -134,6 +134,7 @@ ## 'nph' is true ENV['SERVER_SOFTWARE'] = 'Apache 2.2.0' actual1 = cgi.header('nph'=>true) + now = Time.now ## when old IIS, NPH-mode is forced ENV['SERVER_SOFTWARE'] = 'IIS/4.0' actual2 = cgi.header @@ -143,7 +144,6 @@ actual4 = cgi.header actual5 = cgi.header('status'=>'REDIRECT', 'location'=>'http://www.example.com/') ## assertion - now = Time.now expected = "HTTP/1.1 200 OK\r\n" expected << "Date: #{CGI.rfc1123_date(now)}\r\n" expected << "Server: Apache 2.2.0\r\n" -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/