Updated test to reflect change in IndexManager constrcutor arguments

This commit is contained in:
Richard Miller 2012-08-14 10:04:20 +01:00
commit ce5223f85d
2 changed files with 11 additions and 2 deletions

View file

@ -17,7 +17,16 @@ class IndexManagerTest extends \PHPUnit_Framework_TestCase
'index1' => 'test1',
'index2' => 'test2',
);
$this->indexManager = new IndexManager($this->indexesByName, $this->defaultIndexName);
$defaultIndex = $this->getMockBuilder('Elastica_Index')
->disableOriginalConstructor()
->getMock();
$defaultIndex->expects($this->any())
->method('getName')
->will($this->returnValue($this->defaultIndexName));
$this->indexManager = new IndexManager($this->indexesByName, $defaultIndex);
}
public function testGetAllIndexes()