Download the PHP package lloople/phpunit-extensions without Composer
On this page you can find all versions of the php package lloople/phpunit-extensions. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download lloople/phpunit-extensions
More information about lloople/phpunit-extensions
Files in lloople/phpunit-extensions
Package phpunit-extensions
Short Description 📦 Some cool extensions for PHPUnit
License MIT
Homepage https://github.com/lloople/phpunit-extensions
Informations about the package phpunit-extensions
PHPUnit Extensions
This package provides you a few useful extensions for your testsuite in an effort to improve your code.
Installation
You can install the package via composer:
Add the Extension to your phpunit.xml
file:
Extensions
Console
Output the slowest tests on the console.
Default options are:
- rows:
5
(Report 5 tests max) - min:
200
(Report tests slower than 200ms)
Csv
Write the tests in a CSV file ready for import.
Default options are:
- file:
phpunit_results.csv
- rows:
null
(all the tests) - min:
200
Json
Write the tests in a JSON file ready for import.
Default options are:
- file:
phpunit_results.json
- rows:
null
(all the tests) - min:
200
MySQL
Store the test name and the time into a MySQL database. It will override existing records
Default credentials are (as array):
- database:
phpunit_results
- table:
default
- username:
root
- password: ``
- host:
127.0.0.1
- rows:
null
(all the tests) - min:
200
SQLite
Store the test name and the time into a SQLite database. It will override existing records
Default credentials are (as array):
- database:
phpunit_results.db
- table:
default
- rows:
null
(all the tests) - min:
200
Arguments
To override the default configuration per extension, you need to use <arguments>
in your phpunit.xml
file
In the case of the MySQL and SQLite, which needs a database connection, configuration goes as array
You don't need to override those credentials that already fit to your usecase, since the class will merge your configuration with the default one
Changelog
Please see CHANGELOG for more information what has changed recently.
Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email [email protected] instead of using the issue tracker.
Credits
- David Llop
- All Contributors
Treeware
You're free to use this package, but if it is really useful for you I would highly appreciate you buying the world a tree.
It’s now common knowledge that one of the best tools to tackle the climate crisis and keep our temperatures from rising above 1.5C is to plant trees. If you contribute to Treeware's forest you’ll be creating employment for local families and restoring wildlife habitats.
You can buy trees here offset.earth/treeware
Read more about Treeware at treeware.earth