[前][次][番号順一覧][スレッド一覧]

ruby-changes:24446

From: kazu <ko1@a...>
Date: Mon, 23 Jul 2012 01:56:10 +0900 (JST)
Subject: [ruby-changes:24446] kazu:r36497 (trunk): * test/uri/test_generic.rb (URI#test_find_proxy): add tests with empty *_proxy env variables.

kazu	2012-07-23 01:55:55 +0900 (Mon, 23 Jul 2012)

  New Revision: 36497

  http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=36497

  Log:
    * test/uri/test_generic.rb (URI#test_find_proxy): add tests with empty *_proxy env variables.

  Modified files:
    trunk/ChangeLog
    trunk/test/uri/test_generic.rb

Index: ChangeLog
===================================================================
--- ChangeLog	(revision 36496)
+++ ChangeLog	(revision 36497)
@@ -1,3 +1,8 @@
+Mon Jul 23 01:55:08 2012  Kazuhiro NISHIYAMA  <zn@m...>
+
+	* test/uri/test_generic.rb (URI#test_find_proxy): add tests with
+	  empty *_proxy env variables.
+
 Mon Jul 23 01:47:26 2012  Kazuhiro NISHIYAMA  <zn@m...>
 
 	* test/uri/test_generic.rb (URI#with_env): unset proxy related env
Index: test/uri/test_generic.rb
===================================================================
--- test/uri/test_generic.rb	(revision 36496)
+++ test/uri/test_generic.rb	(revision 36497)
@@ -758,6 +758,14 @@
       assert_equal(URI('http://127.0.0.1:8080'), URI("http://192.0.2.1/").find_proxy)
       assert_nil(URI("http://192.0.2.2/").find_proxy)
     }
+    with_env('http_proxy'=>'') {
+      assert_equal(URI(''), URI("http://192.0.2.1/").find_proxy)
+      assert_nil(URI("ftp://192.0.2.1/").find_proxy)
+    }
+    with_env('ftp_proxy'=>'') {
+      assert_nil(URI("http://192.0.2.1/").find_proxy)
+      assert_equal(URI(''), URI("ftp://192.0.2.1/").find_proxy)
+    }
   end
 
   def test_find_proxy_case_sensitive_env

--
ML: ruby-changes@q...
Info: http://www.atdot.net/~ko1/quickml/

[前][次][番号順一覧][スレッド一覧]