Download the PHP package chinthakagodawita/codeception-timekeeper without Composer
On this page you can find all versions of the php package chinthakagodawita/codeception-timekeeper. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download chinthakagodawita/codeception-timekeeper
More information about chinthakagodawita/codeception-timekeeper
Files in chinthakagodawita/codeception-timekeeper
Package codeception-timekeeper
Short Description A Codeception extension & Robo task that records test runtimes and lets you split tests into equal runtime-based groups for parallel runs
License MIT
Homepage https://github.com/chinthakagodawita/codeception-timekeeper
Informations about the package codeception-timekeeper
Codeception TimeKeeper
A Codeception extension & Robo task that records test runtimes and lets you split tests into equal runtime-based groups for parallel runs.
This can be hugely useful when running your tests in an automated fashion, such as in a Continuous Integration system. You can schedule multiple parallel test runs, each with roughly-equal runtimes.
This extension supports the following Codeception version:
- 3.x
- 4.x
Usage
First, install this package:
Codeception time reporting extension
Update your codeception.yml
with:
Then run your tests, a report with runtimes for each test will be output to _data/time_report.json
. This isn't much use on its own, read on for how you can use this to run your tests in parallel.
Parallel test runs via Robo
Update your Robofile
:
Then update your codeception.yml
file with:
This tells Codeception about the existence of the test groups we've just created.
You'll be able to split tests using:
And run these test groups using:
See the Codeception documentation for more information.
Troubleshooting
Some of my tests depend on each other
This extension does not currently support tests with dependencies. Support for this is coming soon.
Help! I'm seeing strange PHP compatibility errors
If you're seeing errors similar to any of the below, then you've hit a variation of codeception/codeception#5031
The simplest way to fix this, till a real fix lands upstream, is to add the following to the very top of your Robofile
instead of just relying on Composer's autoloader:
Update these paths depending on where your Robofile
lives in relation to Composer's vendor
directory.
This forces Codeception's autoloader to fire and redeclare the PHPUnit classes that it needs to function.
Inspiration
- robo-paracept from the Codeception folks