mirror of https://github.com/FriendsOfTYPO3/tea.git synced 2024-09-19 18:56:13 +02:00

[TASK] Add feature list (#148)

Co-authored-by: Łukasz Uznański <l.uznanski@macopedia.com>
This commit is contained in:
Łukasz Uznański 2020-11-18 12:59:48 +01:00 committed by GitHub
parent 3177d45497
commit 3366e63eff
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -7,8 +7,8 @@
[![Latest Unstable Version](https://poser.pugx.org/ttn/tea/v/unstable.svg)](https://packagist.org/packages/ttn/tea)
[![License](https://poser.pugx.org/ttn/tea/license.svg)](https://packagist.org/packages/ttn/tea)
This TYPO3 extension is an example for writing unit and functional tests for
Extbase/Fluid-based extensions for TYPO3 CMS using PHPUnit.
This TYPO3 extension is an example of best practices in continuous integration and automated code checks, also
writing unit and functional tests for Extbase/Fluid-based extensions for TYPO3 CMS using PHPUnit.
It also is an example for
[best practices for extbase/fluid](https://github.com/oliverklee/workshop-handouts/tree/main/extbase-best-practices).
@ -16,11 +16,44 @@ It also is an example for
For information on the different ways to execute the tests, please have a look
at the [handout to my workshops on test-driven development (TDD)](https://github.com/oliverklee/tdd-reader).
## Running the unit tests from the command line
## Feature list
All of those checks are available in Github Actions and in Gitlab CI.
```bash
composer ci:tests:unit
```
### PHP Lint check by php -l
`composer ci:php:lint`
### PHP CodeStyle check by [php-cs-fixer](https://github.com/FriendsOfPHP/PHP-CS-Fixer)
`composer ci:php:codestyle`
### PHP Sniff by phpcs [phpcs](https://github.com/squizlabs/PHP_CodeSniffer)
`composer ci:php:sniff`
### JSON Lint check by [jsonlint](https://github.com/Seldaek/jsonlint)
`composer ci:json:lint`
### YAML Lint check by [yaml-lint](https://github.com/j13k/yaml-lint)
`composer ci:yaml:lint`
### TypoScript Lint by [typoscript-lint](https://github.com/martin-helmich/typo3-typoscript-lint)
`composer ci:ts:lint`
### Runinng unit tests
`composer ci:tests:unit`
### Runinng functional tests tests
`composer ci:tests:functional`
### Runinng all tests
`composer ci:tests`
## Running the tests in PhpStorm
@ -73,12 +106,6 @@ In the Run configurations, copy the PHPUnit configuration and use these settings
2. right-click on `Tests/Acceptance/StarterCest.php`
3. Run 'Acceptance (Codeception)'
## Creating new extensions with automated tests
For creating new extensions, I recommend taking
[Helmut Hummel's extension skeleton](https://github.com/helhum/ext_scaffold)
as a starting point.
## Security
Libraries and extensions do not need the security check as they should not have