public function testDeleteIndex()
{
$index = $this->getMockBuilder('Elastica\\Index')->disableOriginalConstructor()->setMethods(array('delete'))->getMock();
$index->expects($this->once())->method('delete');
$this->elasticaClient->expects($this->once())->method('getIndex')->with('comments')->will($this->returnValue($index));
$this->client->deleteIndex('comments');
}