Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wavevision/nette-tests
🧰 PHPUnit extension for testing @nette applications
https://github.com/wavevision/nette-tests
nette nette-tests phpunit testing
Last synced: about 1 month ago
JSON representation
🧰 PHPUnit extension for testing @nette applications
- Host: GitHub
- URL: https://github.com/wavevision/nette-tests
- Owner: wavevision
- License: mit
- Archived: true
- Created: 2019-10-10T09:40:41.000Z (about 5 years ago)
- Default Branch: master
- Last Pushed: 2023-04-19T18:26:28.000Z (over 1 year ago)
- Last Synced: 2024-08-25T12:40:56.352Z (2 months ago)
- Topics: nette, nette-tests, phpunit, testing
- Language: PHP
- Homepage:
- Size: 714 KB
- Stars: 6
- Watchers: 4
- Forks: 1
- Open Issues: 6
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
Nette Tests
[![CI](https://github.com/wavevision/nette-tests/workflows/CI/badge.svg)](https://github.com/wavevision/nette-tests/actions/workflows/ci.yml)
[![Coverage Status](https://coveralls.io/repos/github/wavevision/nette-tests/badge.svg?branch=master)](https://coveralls.io/github/wavevision/nette-tests?branch=master)
[![PHPStan](https://img.shields.io/badge/style-level%20max-brightgreen.svg?label=phpstan)](https://github.com/phpstan/phpstan)[PHPUnit](https://github.com/sebastianbergmann/phpunit/) extension for testing [Nette](https://github.com/nette/nette)
applications.## Install
```
composer require --dev wavevision/nette-tests
```## Configuration
Add callback for creating `Nette\Configurator` to [bootstrap](tests/app/tests/bootstrap.php) for tests.
## Features
* [DI container](tests/app/tests/Models/ExampleModelTest.php) in tests, allow
services [injects](tests/app/tests/Models/ExampleModelTest.php) in tests
* [presenter](tests/app/tests/Presenters/ExamplePresenterTest.php) testing
* [form](tests/app/tests/Presenters/FormPresenterTest.php) submit testing### Presenter mapping
This testing suite lets you use your presenter classes to resolve `:Module:Presenter:action` mapping. This is achieved
using [nepada/presenter-mapping](https://github.com/nepada/presenter-mapping) extension which is registered in your
tests DIC as `presenterMapping`.If your tested app uses this extension for presenter mapping as well, **make sure you register it in your config with
the same name**.## Learn
See [this great talk](https://www.youtube.com/watch?v=E1r0EhTkWn4) by [Jakub Filla](https://github.com/jfilla) to learn
basic concepts of this extension.