public function testLimitReset() { $pipeline = new Pipeline($this->collection); $pipeline->limit(11)->match(array('a' => 1, 'b' => array('$lt' => 12)))->limit(23); $this->assertEquals('[{"$limit":11},{"$match":{"a":1,"b":{"$lt":12}}},{"$limit":23}]', (string) $pipeline); }