Skip to content


Subversion checkout URL

You can clone with
Download ZIP
branch: master
Fetching contributors…

Cannot retrieve contributors at this time

executable file 75 lines (60 sloc) 2.014 kB
namespace <?php echo $namespace ?>\Tests\Functional;
// Set-up composer auto-loading if Client is insulated.
call_user_func(function() {
if ( ! is_file($autoloadFile = __DIR__.'/../../vendor/autoload.php')) {
throw new \LogicException('The autoload file "vendor/autoload.php" was not found. Did you run "composer install --dev"?');
require_once $autoloadFile;
use Symfony\Component\Filesystem\Filesystem;
use Symfony\Component\Config\Loader\LoaderInterface;
use Symfony\Component\HttpKernel\Kernel;
class AppKernel extends Kernel
private $config;
public function __construct($config)
parent::__construct('test', true);
$fs = new Filesystem();
if (!$fs->isAbsolutePath($config)) {
$config = __DIR__.'/config/'.$config;
if ( ! is_file($config)) {
throw new \RuntimeException(sprintf('The config file "%s" does not exist.', $config));
$this->config = $config;
public function registerBundles()
return array(
new \Symfony\Bundle\FrameworkBundle\FrameworkBundle(),
<?php if ($withDatabase): ?>
new \Doctrine\Bundle\DoctrineBundle\DoctrineBundle(),
new \Doctrine\Bundle\FixturesBundle\DoctrineFixturesBundle(),
<?php endif ?>
new \Symfony\Bundle\TwigBundle\TwigBundle(),
new \<?php echo $namespace ?>\<?php echo $name ?>(),
public function registerContainerConfiguration(LoaderInterface $loader)
public function getCacheDir()
return sys_get_temp_dir().'/'.Kernel::VERSION.'/<?php echo $name ?>/cache';
public function getLogDir()
return sys_get_temp_dir().'/'.Kernel::VERSION.'/<?php echo $name ?>/logs';
public function serialize()
return $this->config;
public function unserialize($config)
Jump to Line
Something went wrong with that request. Please try again.