Skip to content
Permalink
Browse files
Small fix in test_attachstream and test_mapaddress
Continuing to address ticket #8692.
  • Loading branch information
saturn597 committed May 30, 2013
1 parent a6ee882 commit acb5aee2620ee8668c308e1fb7b5a905863b2efe
Showing with 4 additions and 3 deletions.
  1. +4 −3 test/integ/control/controller.py
@@ -805,9 +805,6 @@ def test_mapaddress(self):
test.network.negotiate_socks(s, '1.2.1.2', 80)
s.sendall(test.network.ip_request) # make the http request for the ip address
response = s.recv(1000)
# everything after the blank line is the 'data' in a HTTP response.
# The response data for our request for request should be an IP address + '\n'
print response
if response:
break
except (stem.ProtocolError, socket.timeout):
@@ -817,7 +814,11 @@ def test_mapaddress(self):
s.close()

self.assertTrue(response)

# everything after the blank line is the 'data' in a HTTP response.
# The response data for our request for request should be an IP address + '\n'
ip_addr = response[response.find("\r\n\r\n"):].strip()

self.assertTrue(stem.util.connection.is_valid_ipv4_address(ip_addr))

def test_get_microdescriptor(self):

0 comments on commit acb5aee

Please sign in to comment.