IP to Geo

IP to Geo Commit Details

Date:2016-02-04 20:39:50 (4 years 8 months ago)
Author:Grégory Soutadé
Branch:master
Commit:36d5b0f43beb730b8c9eda2995079de0a122c5a2
Parents: f3c8feb3c50becabfcccc728723a710a033ede89
Message:Print a message at then end of test

Changes:
Mtests/test_ip_to_geo.py (2 diffs)

File differences

tests/test_ip_to_geo.py
44
55
66
7
7
8
9
810
11
912
1013
1114
......
5962
6063
6164
65
66
import os
from iptogeo import IPToGeo, IPToGeoException
TIMEOUT=3
TIMEOUT = None
# TIMEOUT = 5.0
iptogeo = IPToGeo(timeout=TIMEOUT)
def get_random_ip_v4():
ip = '%d.%d.%d.%d' % \
(ord(os.urandom(1)), ord(os.urandom(1)), ord(os.urandom(1)), ord(os.urandom(1)))
print 'Test %d' % (i)
for proxy in geo_proxy:
test_ip(get_random_ip_v4(), verbose=False, proxy=proxy)
print 'All is OK for me'

Archive Download the corresponding diff file

Branches

Tags