コード例 #1
0
 def test_country_code(self):
     a = Babe().pull(string=self.s, format='csv')
     a = a.geoip_country_code()
     self.assertEquals(a.to_string(), self.s2)
コード例 #2
0
 def test_country_code(self):
     a = Babe().pull(stream=StringIO(self.s), format='csv')
     a = a.geoip_country_code()
     buf = StringIO()
     a.push(stream=buf, format="csv")
     self.assertEquals(buf.getvalue(), self.s2)
コード例 #3
0
 def test_country_code(self):
     a = Babe().pull(string=self.s, format='csv')
     a = a.geoip_country_code()
     self.assertEquals(a.to_string(), self.s2)
コード例 #4
0
ファイル: tests.py プロジェクト: nizox/PyBabe
 def test_country_code(self): 
     a = Babe().pull(stream=StringIO(self.s), format='csv')
     a = a.geoip_country_code()
     buf = StringIO()
     a.push(stream=buf, format="csv")
     self.assertEquals(buf.getvalue(), self.s2)