public function testCount() { $this->prepareData(); $collection = $this->getCollection(); $cursor = $collection->find(['foo' => 'bar'])->limit(1); $this->assertSame(2, $cursor->count()); $this->assertSame(1, $cursor->count(true)); }