您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

test_geo_ip.py 469 B

12345678910111213
  1. # Copyright (c) 2013, Web Notes Technologies Pvt. Ltd. and Contributors
  2. # MIT License. See license.txt
  3. import webnotes
  4. import unittest
  5. class TestGeoIP(unittest.TestCase):
  6. def test_geo_ip(self):
  7. return
  8. from webnotes.sessions import get_geo_ip_country
  9. self.assertEquals(get_geo_ip_country("223.29.223.255"), "India")
  10. self.assertEquals(get_geo_ip_country("4.18.32.80"), "United States")
  11. self.assertEquals(get_geo_ip_country("217.194.147.25"), "United States")