summaryrefslogtreecommitdiff
path: root/test/test_poolmanager.py
diff options
context:
space:
mode:
authorAndrey Petrov <andrey.petrov@shazow.net>2014-06-24 16:26:44 -0700
committerAndrey Petrov <andrey.petrov@shazow.net>2014-06-24 16:26:44 -0700
commit95fafd865718bd40e9d554e1396144e56af6fd5e (patch)
tree764ae4614c30922b618487804210c662a0fb7ef0 /test/test_poolmanager.py
parent26e4ef9084adcce1b0f854f5431ed92519d47fb5 (diff)
downloadurllib3-95fafd865718bd40e9d554e1396144e56af6fd5e.tar.gz
Handle blank host with new exception, LocationValueError.
Diffstat (limited to 'test/test_poolmanager.py')
-rw-r--r--test/test_poolmanager.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/test/test_poolmanager.py b/test/test_poolmanager.py
index 759b5e33..754ee8a7 100644
--- a/test/test_poolmanager.py
+++ b/test/test_poolmanager.py
@@ -4,7 +4,7 @@ from urllib3.poolmanager import PoolManager
from urllib3 import connection_from_url
from urllib3.exceptions import (
ClosedPoolError,
- LocationParseError,
+ LocationValueError,
)
@@ -68,7 +68,8 @@ class TestPoolManager(unittest.TestCase):
def test_nohost(self):
p = PoolManager(5)
- self.assertRaises(LocationParseError, p.connection_from_url, 'http://@')
+ self.assertRaises(LocationValueError, p.connection_from_url, 'http://@')
+ self.assertRaises(LocationValueError, p.connection_from_url, None)
if __name__ == '__main__':