riconet / t3-extension-skeleton
This project contains a skeleton for TYPO3-Extbase extensions.
Installs: 25
Dependents: 0
Suggesters: 0
Security: 0
Type:project
pkg:composer/riconet/t3-extension-skeleton
Requires
- php: ^7.0
Replaces
- riconet/extension-skeleton: 9.5.5
README
Need to know
- This project assumes you are using gitlab, to host your extension.
- The vendor is currently defined static (This is going to change soon, dont worry.)
- There is no support for windows, currently.
Description
This composer project was created, to ease the process of creating a new extension, for the CMS TYPO3. This setup contains the commonly used files and folders, to create an extension. It also provides a configuration, to run unit and functional tests and ships a fully working gitlab-ci.yml.
How to create a new extension / How to use this project
Open your shell and navigate to the destination of your upcoming extension. Execute the following command and remember to define a name for your extension.
composer create-project riconet/t3-extension-skeleton:VERSION EXTENSION_KEY
How to run the tests
After you wrote some test files, run composer install in the root of the extension.
This will create a new folder, called .Build. 
This folder contains a TYPO3 instance (with your extension linked), a shell script for test execution and a docker-compose.yml.
You can also run code quality checks, to check your source code.
To run tests, execute the script Build/Scripts/runTests.sh.
How to use the runTests.sh script
Extension test runner. Execute unit test suite and some other details.
Options
-s <...>
    Specifies which test suite to run
        - build: Builds the project (composer)
        - lint: Lints the php files
        - functional: functional tests
        - unit (default): PHP unit tests
        - quality: executes code quality checks (phpstan, phpcs, phpmd)
        - find-debugs: Finds usages of debug calls.
-p <7.0|7.1|7.2|7.3>
    Specifies the PHP minor version to be used
        - 7.0 (default): use PHP 7.0
        - 7.3: use PHP 7.3
-e "<phpunit options>"
    Only with -s functional|unit
    Additional options to send to phpunit (unit & functional tests).
    Starting with "--" must be added after options starting with "-".
    Example -e "-v --filter canRetrieveValueWithGP" to enable verbose output AND filter tests
    named "canRetrieveValueWithGP"
-h
    Show this help.
Examples:
Run unit tests:
/Build/Scripts/runTests.sh -s unit