public function testAddTypes()
{
$client = $this->_getClient();
$search = new Search($client);
$index = $this->_createIndex();
$types = array();
$types[] = $index->getType('type1');
$types[] = $index->getType('type2');
$search->addTypes($types);
$this->assertEquals(2, count($search->getTypes()));
}