def test_limit_iterator(self):
        
        result_fetcher = functools.partial(self.protocol.get, '/athlete/activities')
        results = BatchedResultsIterator(entity=model.Activity, result_fetcher=result_fetcher, limit=10, per_page=2)
        results.limit = 10
        results = list(results)
        self.assertEquals(10, len(results))
            
        
        # TODO: use a mock here to figure out how many calls are happening under the hood.
Test setting the limit on the iterator.
dataset/ETHPy150Open hozn/stravalib/stravalib/tests/functional/test_result_iterator.py/ResultIteratorTest.test_limit_iterator