public function testCountReturnsResultsCount() { $index = $this->getIndex(); $result = array(1, 2); $index->expects($this->any())->method('find')->will($this->returnValue($result)); $a = new Zle_Paginator_Adapter_Lucene($index, 'foo'); $this->assertEquals(count($result), $a->count()); }