for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
namespace Yoanm\Behat3SymfonyExtension\Kernel;
use Symfony\Component\EventDispatcher\EventDispatcher;
use Yoanm\Behat3SymfonyExtension\Context\BehatDispatcherAwareInterface;
use Yoanm\Behat3SymfonyExtension\Event\Events;
use Yoanm\Behat3SymfonyExtension\Event\KernelEvent;
class Kernel implements BehatDispatcherAwareInterface
{
/** @var EventDispatcher */
private $eventDispatcher;
/**
* @inheritDoc
*/
public function setBehatDispatcher(EventDispatcher $eventDispatcher)
$this->eventDispatcher = $eventDispatcher;
}
* {@inheritdoc}
public function boot()
if (true === $this->booted) {
return;
$event = new KernelEvent($this);
$this->eventDispatcher->dispatch(
Events::BEFORE_KERNEL_BOOT,
$event
);
parent::boot();
Events::AFTER_KERNEL_BOOT,
public function shutdown()
if (false === $this->booted) {
Events::BEFORE_KERNEL_SHUTDOWN,
parent::shutdown();
Events::AFTER_KERNEL_SHUTDOWN,