PHPackages                             yoanm/behat3-symfony-extension - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. yoanm/behat3-symfony-extension

AbandonedArchivedLibrary

yoanm/behat3-symfony-extension
==============================

Symfony extension for Behat V3

0.2.1(9y ago)016[2 issues](https://github.com/yoanm/Behat3SymfonyExtension/issues)MITPHPPHP &gt;=5.5

Since Dec 12Pushed 9y ago1 watchersCompare

[ Source](https://github.com/yoanm/Behat3SymfonyExtension)[ Packagist](https://packagist.org/packages/yoanm/behat3-symfony-extension)[ RSS](/packages/yoanm-behat3-symfony-extension/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (3)Dependencies (9)Versions (4)Used By (0)

Behat3SymfonyExtension
======================

[](#behat3symfonyextension)

[![Scrutinizer Build Status](https://camo.githubusercontent.com/cad6f53427219db3d027c14371606b9804295f6d0492d23b678ad69fb2f26a0b/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f6275696c642f672f796f616e6d2f42656861743353796d666f6e79457874656e73696f6e2e7376673f6c6162656c3d5363727574696e697a6572)](https://scrutinizer-ci.com/g/yoanm/Behat3SymfonyExtension/?branch=master) [![Scrutinizer Code Quality](https://camo.githubusercontent.com/27bb4db9b113d08aa0e0791aeca0f3230b6db9e3559a38ece7e29948560f1a80/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f672f796f616e6d2f42656861743353796d666f6e79457874656e73696f6e2e7376673f6c6162656c3d436f64652532307175616c697479)](https://scrutinizer-ci.com/g/yoanm/Behat3SymfonyExtension/?branch=master) [![Code Coverage](https://camo.githubusercontent.com/beb3903c1d08c8f919d69dc83dbe33861fc8e821cf3ca1f982381e35bf89042d/68747470733a2f2f696d672e736869656c64732e696f2f7363727574696e697a65722f636f7665726167652f672f796f616e6d2f42656861743353796d666f6e79457874656e73696f6e2e7376673f6c6162656c3d436f766572616765)](https://scrutinizer-ci.com/g/yoanm/Behat3SymfonyExtension/?branch=master)

[![Travis Build Status](https://camo.githubusercontent.com/5b8b4aba8d57a0ec9b2d1af954fb61bfcaeed9d65b684111de01aa955f4b7931/68747470733a2f2f696d672e736869656c64732e696f2f7472617669732f796f616e6d2f42656861743353796d666f6e79457874656e73696f6e2f6d61737465722e7376673f6c6162656c3d747261766973)](https://travis-ci.org/yoanm/Behat3SymfonyExtension) [![PHP Versions](https://camo.githubusercontent.com/26d093a903092111aa1f2004841957e69e68af14b00202ad27f256949810c9a9/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f7068702d352e35253230253246253230352e36253230253246253230372e302d3838393242462e737667)](https://php.net/) [![Symfony Versions](https://camo.githubusercontent.com/190e51ca3517d09f443b8e34c168153cdd110a8b132f06383a92a9c49488a918/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f53796d666f6e792d322e37253230253246253230322e38253230253246253230332e302d3331323933332e737667)](https://symfony.com/)

[![Latest Stable Version](https://camo.githubusercontent.com/5293d85df9059a8701a4678950bd581182ab423781954de8cd05bcb1c7b4aaf6/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f796f616e6d2f6265686174332d73796d666f6e792d657874656e73696f6e2e737667)](https://packagist.org/packages/yoanm/behat3-symfony-extension)

Behat3SymfonyExtension is a layer between Behat 3.0+ and Symfony2.7+|3+, strongly inspired by [Symfony2Extension](https://github.com/Behat/Symfony2Extension).

- [Why](#why)
- [Install](#install)
- [How to use](#how-to-use)
    - [Configuration](#configuration)
- [In the box](#in-the-box)
    - [`Client`](#client)
    - [`KernelAwareInterface`](#kernelawareinterface)
    - [`LoggerAwareInterface`](#loggerawareinterface)
    - [`SfKernelEventLogger`](#sfkerneleventlogger)
    - [Debug mode](#debug-mode)
- [Default configuration reference](#default-configuration-reference)
- [Tests](#tests)
- [Contributing](#contributing)

Why
===

[](#why)

See [Why ? Or rather, why not Symfony2Extension ?](./doc/why-explanation.md#why--or-rather-why-not-symfony2extension-)

Install
=======

[](#install)

```
> composer require --dev yoanm/behat3-symfony-extension
```

How to use
==========

[](#how-to-use)

Behat3SymfonyExtension require [yoanm/behat-utils-extension](https://github.com/yoanm/BehatUtilsExtension), [behat/behat](https://github.com/Behat/Behat), [monolog/monolog](https://github.com/Seldaek/monolog), [symfony/browser-kit](https://github.com/symfony/browser-kit) and [symfony/framework-bundle](https://github.com/symfony/framework-bundle)

Configuration
-------------

[](#configuration)

Add the following in your behat configuration file (usually `behat.yml`) :

```
default:
    extensions:
        Yoanm\BehatUtilsExtension: ~
        Yoanm\Behat3SymfonyExtension: ~
```

To use the `behat3Symfony` driver for mink (created thanks to [`Behat3SymfonyDriverFactory`](./src/Yoanm/Behat3SymfonyExtension/ServiceContainer/DriverFactory/Behat3SymfonyDriverFactory.php)), install and configure [behat/mink-extension](https://github.com/Behat/MinkExtension) and [behat/mink-browserkit-driver](https://github.com/Behat/MinkBrowserKitDriver). Then, add the following in your behat configuration file :

```
default:
    extensions:
        Behat\MinkExtension:
            sessions:
                my_session:
                    behat3Symfony: ~
```

In the box
==========

[](#in-the-box)

[`Client`](./src/Yoanm/Behat3SymfonyExtension/Client/Client.php)
----------------------------------------------------------------

[](#client)

It will be used by the mink driver if mink installed and configured to use the `behat3Symfony` driver

[`KernelAwareInterface`](./src/Yoanm/Behat3SymfonyExtension/Context/KernelAwareInterface.php)
---------------------------------------------------------------------------------------------

[](#kernelawareinterface)

Will inject your symfony app kernel instance in your behat contexts

[`LoggerAwareInterface`](./src/Yoanm/Behat3SymfonyExtension/Context/LoggerAwareInterface.php)
---------------------------------------------------------------------------------------------

[](#loggerawareinterface)

Will inject a monolog logger instance in your behat contexts

[`SfKernelEventLogger`](./src/Yoanm/Behat3SymfonyExtension/Logger/SfKernelEventLogger.php)
------------------------------------------------------------------------------------------

[](#sfkerneleventlogger)

**Only in case where `kernel.debug` is set to true** (see default kernel configuration below). Produce a log entry each time that your symfony application kernel will :

- handle a request
- catch an exception

All data are loggued in the configured file (see default logger configuration below)

Debug mode
----------

[](#debug-mode)

To enable extension debug mode, add the following in your behat configuration file :

```
default:
    extensions:
        Yoanm\Behat3SymfonyExtension:
            debug_mode: true
```

This mode allow two things :

- Kernel bridge class file is not deleted. If you have some errors related to the bridge, it will be easier for debug.
- Some new log entry are added, regarding Kernel bridge and Client behavior

In case you just want the log entry, just add the following in your behat configuration file :

```
default:
    extensions:
        Yoanm\BehatUtilsExtension:
             logger:
                level: DEBUG
```

Configuration reference
=======================

[](#configuration-reference)

```
default:
    extensions:
        Yoanm\Behat3SymfonyExtension:
            debug_mode: false
            kernel:
                bootstrap: app/autoload.php
                path: app/AppKernel.php
                class: AppKernel
                env: test
                debug: true
                reboot: true # If true symfony kernel will be rebooted BEFORE each scenario/example
```

Tests
=====

[](#tests)

This repository follow a [custom test strategy](https://gist.github.com/yoanm/3944890d0adda5fc7e0c306a1870727d#file-tests-md)

Contributing
============

[](#contributing)

See [contributing note](./CONTRIBUTING.md)

###  Health Score

23

—

LowBetter than 27% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity6

Limited adoption so far

Community7

Small or concentrated contributor base

Maturity50

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~11 days

Total

3

Last Release

3417d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/4410697?v=4)[yoanm](/maintainers/yoanm)[@yoanm](https://github.com/yoanm)

---

Top Contributors

[![yoanm](https://avatars.githubusercontent.com/u/4410697?v=4)](https://github.com/yoanm "yoanm (54 commits)")

---

Tags

symfonybehat3

###  Code Quality

TestsPHPUnit

Code StylePHP\_CodeSniffer

### Embed Badge

![Health badge](/badges/yoanm-behat3-symfony-extension/health.svg)

```
[![Health](https://phpackages.com/badges/yoanm-behat3-symfony-extension/health.svg)](https://phpackages.com/packages/yoanm-behat3-symfony-extension)
```

###  Alternatives

[scheb/2fa

Two-factor authentication for Symfony applications (please use scheb/2fa-bundle to install)

578630.7k1](/packages/scheb-2fa)[jolicode/gif-exception-bundle

The GhostBuster of your exception page

20596.8k](/packages/jolicode-gif-exception-bundle)[sulu/skeleton

Project template for starting your new project based on the Sulu content management system

29733.3k](/packages/sulu-skeleton)[rcsofttech/audit-trail-bundle

Enterprise-grade, high-performance Symfony audit trail bundle. Automatically track Doctrine entity changes with split-phase architecture, multiple transports (HTTP, Queue, Doctrine), and sensitive data masking.

1022.4k](/packages/rcsofttech-audit-trail-bundle)[ahmed-bhs/doctrine-doctor

Runtime analysis tool for Doctrine ORM integrated into Symfony Web Profiler. Unlike static linters, it analyzes actual query execution at runtime to detect performance bottlenecks, security vulnerabilities, and best practice violations during development with real execution context and data.

813.1k](/packages/ahmed-bhs-doctrine-doctor)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
