Skip to content

Commit

Permalink
testing limit added
Browse files Browse the repository at this point in the history
  • Loading branch information
josuebrunel committed Aug 23, 2015
1 parent c93442e commit e3bd587
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions tests/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,12 @@ def setUp(self,):
def tearDown(self,):
pass

def test_limit(self,):
data = self.yql.select('geo.states', limit=3, offset=2).where(['place', '=', 'Congo'])
logging.debug(pretty_json(data.content))
self.assertEqual(data.status_code, 200)
self.assertEqual(data.json()['query']['count'], 3)

def test_offset_raw_query(self,):
data = self.yql.raw_query("SELECT * FROM geo.counties WHERE place='CA' LIMIT 10 OFFSET 5 | sort(field='name')")
logging.debug(pretty_json(data.content))
Expand Down

0 comments on commit e3bd587

Please sign in to comment.