Download the PHP package nexendrie/testbench without Composer
On this page you can find all versions of the php package nexendrie/testbench. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download nexendrie/testbench
More information about nexendrie/testbench
Files in nexendrie/testbench
Package testbench
Short Description Simple integration testing tool for Nette Framework applications
License BSD-3-Clause GPL-2.0 GPL-3.0
Informations about the package testbench
Testbench
Tested against PHP 7.4. Please read this wiki.
Heavily inspired by these GitHub projects:
- Kdyby/TesterExtras, Librette tests, Nette tests and damejidlo/modular-testcase
And article(s):
- Bootstrap your integration testing database (Jiří Pudil)
- Testování presenterů v Nette (Martin Zlámal)
Simple test bench for Nette Framework projects
Write integration tests as simple as possible. This project helps you to write tests very quickly. DRY! The main goal of this project is to make testing very simple for everyone and help with the difficult start.
You can find few examples in this readme or take a look to the tests folder in this project.
Installation
Minimal code
At first, you need classic bootstrap file (just example, DIY):
It's important, that we are not creating dependency injection container here. You can use autoload from composer if you don't want to use robot loader.
And you are ready to go:
You can easily write cover with tests UI\Controls, restricted areas, forms, signals, redirects, ...
Please read this article.
Give it a shot!
Look at the tests in this project. You'll see how to use it properly. There are examples in tests folder or in the wiki. Learn how to use these traits:
All versions of testbench with dependencies
kdyby/fake-session Version ^2.1 || ^3.0
nette/bootstrap Version ^2.4.6 || ^3.0
nette/di Version ^2.4.16 || ^3.0.5
nette/safe-stream Version ^2.4.1
nette/tester Version ^2.3.3
nette/utils Version ^2.5.4 || ^3.1.3
nette/application Version ^2.4.16 || ^3.0.7
nette/security Version ^2.4.4 || ^3.0.5