FOSElasticaBundle/Tests/Functional/ConfigurationManagerTest.php
2014-06-16 23:23:49 +10:00

55 lines
1.1 KiB
PHP

<?php
/**
* This file is part of the FOSElasticaBundle project.
*
* (c) Tim Nagel <tim@nagel.com.au>
*
* This source file is subject to the MIT license that is bundled
* with this source code in the file LICENSE.
*/
namespace FOS\ElasticaBundle\Tests\Functional;
use Symfony\Bundle\FrameworkBundle\Client;
/**
* @group functional
*/
class ConfigurationManagerTest extends WebTestCase
{
public function testContainerSource()
{
$client = $this->createClient(array('test_case' => 'Basic'));
$manager = $this->getManager($client);
$index = $manager->getIndexConfiguration('index');
var_dump($index); die;
}
protected function setUp()
{
parent::setUp();
$this->deleteTmpDir('Basic');
}
protected function tearDown()
{
parent::tearDown();
$this->deleteTmpDir('Basic');
}
/**
* @param Client $client
* @return \FOS\ElasticaBundle\Configuration\Manager
*/
private function getManager(Client $client)
{
$manager = $client->getContainer()->get('fos_elastica.config_manager');
return $manager;
}
}