Download the PHP package gquemener/behat-analysis-extension without Composer
On this page you can find all versions of the php package gquemener/behat-analysis-extension. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download gquemener/behat-analysis-extension
More information about gquemener/behat-analysis-extension
Files in gquemener/behat-analysis-extension
Package behat-analysis-extension
Short Description Analysis tool for Behat
License MIT
Informations about the package behat-analysis-extension
Behat analysis extension
Introduction
Well, I always start asking "why?" when encoutering some crazy project. So, I will start by answering this trivial question.
I've simply realised that the more a project grows, the more its FeatureContext
also grows!
Some of the ones I've worked on have more than 1000 lines of code and it suffers from the same maintainability issues than any other huge class.
Many great tools already exists to provide solution against this drawback: OOP, SubContexts, PageObjectContext, ...
But still, sometimes you need to look at your past and try to improve what you've done and that's why I've done this extension!
This extension provides some basic analysis about your step definitions. For the moment, it focuses on rarely used steps and similar ones.
Installation
-
Define dependencies in your
composer.json
: -
Install/update your vendors:
- Activate extension by specifying its class in your
behat.yml
:
Usage
After installation, a new analysis
formatter should be available.
Then, run your feature suite using it:
NB: It's recommended (but not mandatory) to run the analysis using the --dry-run
option to accelerate the report generation.
Example
Contribution
It is more than welcome as always!
Feel free to contact me on twitter @GildasQ or through the issue system.