From 3366e63eff9861e9e5133a1cdfb839acc5009763 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=81ukasz=20Uzna=C5=84ski?= Date: Wed, 18 Nov 2020 12:59:48 +0100 Subject: [PATCH] [TASK] Add feature list (#148) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Łukasz Uznański --- README.md | 51 +++++++++++++++++++++++++++++++++++++++------------ 1 file changed, 39 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 3a0d550..0135467 100644 --- a/README.md +++ b/README.md @@ -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