[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]

[tor-commits] [bridgedb/master] Add test for proxy.ProxySet with missing PROXY_LIST_FILE.



commit 164c545622c3940b3f25eccf561b999899fa16b5
Author: Isis Lovecruft <isis@xxxxxxxxxxxxxx>
Date:   Thu Mar 19 04:13:51 2015 +0000

    Add test for proxy.ProxySet with missing PROXY_LIST_FILE.
---
 lib/bridgedb/test/test_proxy.py |    5 +++++
 1 file changed, 5 insertions(+)

diff --git a/lib/bridgedb/test/test_proxy.py b/lib/bridgedb/test/test_proxy.py
index 144cf70..6d62f22 100644
--- a/lib/bridgedb/test/test_proxy.py
+++ b/lib/bridgedb/test/test_proxy.py
@@ -157,6 +157,11 @@ class LoadProxiesFromFileIntegrationTests(unittest.TestCase):
         proxies = proxy.loadProxiesFromFile(self.fn0)
         self.assertEqual(len(proxies), 3)
 
+    def test_proxy_loadProxiesFromFile_1_file_missing(self):
+        """Test loading proxies from one file that doesn't exist."""
+        proxies = proxy.loadProxiesFromFile('%s-missing' % self.__class__.__name__)
+        self.assertEqual(len(proxies), 0)
+
     def test_proxy_loadProxiesFromFile_1_file_and_proxyset(self):
         """Test loading proxies from one file."""
         proxyList = proxy.ProxySet(['1.1.1.1'])



_______________________________________________
tor-commits mailing list
tor-commits@xxxxxxxxxxxxxxxxxxxx
https://lists.torproject.org/cgi-bin/mailman/listinfo/tor-commits