mirror of https://github.com/FriendsOfTYPO3/tea.git synced 2024-11-25 22:56:17 +01:00
Commit graph

19 commits

Author SHA1 Message Date
Stefan Bürk
00ba733b0e
[FEATURE] Integrate runTests.sh execution wrapper - round one (#900)
TYPO3 Core and related repositories like the `typo3/testing-framework`
or `typo3/styleguide` uses a bash script arround docker to execute all
scripts over different operating systems in a controlled and ensured
manner. This helps to reproduce locally failing jobs from a CI like
GitHub actions or GitLab.

TYPO3 core dropped recently the requirement for `docker-compose`,
reducing it to `docker` and preparing for dual usage with docker
and podman in the future.

This change integrates the current state as extension wrapper,
aligning contained suits with existing tools. Additionally, a
TYPO3 core version switch is integrated.

The added script is excluded from git archive building and
during releasing.

A list of possible options can be display with:

```shell
Build/Scripts/runTests.sh -h
```

Overview of integrated features:

* `-p` to select the PHP version (7.4 - 8.3)
* `-s` to select the suite to execute
* `-t` to select the TYPO3 core version, mainly
  needed for the `composer` suits executions
* `-e` to provide additionally flags for phpunit
  executions, e.g. for unit and functional tests
* `-x` to enable xdebug trigger - this helps with
  debugging during unit or functional test
* `-d` to select the database backend to use, needed
  for functional test execution to start the correct
  database
* `-a` to select the used php driver for the `-d`
  database backend, if multiple options are possible
* `-i` to specify the mariadb version
* `-j` to specify the mysql version
* `-k` to specify the postgres version

Available suits (`-s`):

- cgl: Checks the code style with the PHP Coding Standards Fixer
  (PHP-CS-Fixer).
- cglFix: Fixes the code style with PHP-CS-Fixer."
- clean: clean up build, cache and testing related files and
  folders
- cleanBuild: clean up build related files and folders
- cleanCache: clean up cache related files and folders
- cleanRenderedDocumentation: clean up rendered documentation
  files and folders (Documentation-GENERATED-temp)
- cleanTests: clean up test related files and folders
- composer: "composer" with all remaining arguments dispatched.
- composerInstallMax: "composer update", with no platform.php config.
- composerInstallMin: "composer update --prefer-lowest", with
  platform.php set to PHP version x.x.0.
- docsGenerate: Renders the extension ReST documentation.
- functional: PHP functional tests
- lintTypoScript: TypoScript linting
- lintPhp: PHP linting
- lintJson: JSON linting
- lintYaml: YAML linting
- phpstan: phpstan tests
- phpstanGenerateBaseline: regenerate phpstan baseline, handy after
  phpstan updates
- unit (default): PHP unit tests
- unitRandom: PHP unit tests in random order, add -o <number> to use
  specific seed

Notes:

* Not everything is available directly for now in the `runTests.sh`
  and therefore not enabled in CI.

* Coverage related execution needs extended work and are therefore
  left out for now.

* `composer.json` protection for core version changes not included
  yet like the one or other advanced option.

* Intermediate cleanings for changing php versions and core versions
  not included yet and will follow.

* typo3/testing-framework template files **must** be copied to the
  extension or project and **must not** be used from the  vendor
  folder.

Resolves: #899
Releases: main
2023-07-31 13:38:07 +02:00
Oliver Klee
d0c819d3a6
[TASK] Avoid race condition on case-insensitive filesystems (#657)
Case-insensitive filesystems cannot distinguish properly for
file and folder names with different casings. This leads to
unforseeable issues on these systems, like default partition
on MacOS devices from apple or eventually Windows systems.

This change configure phpcoverall and the chain explicitly to
use folders for the files which differs from the default of
`build/*` to avoid conflicts on case-insensitve filesystems
and prepare for introduction of the upcoming implementation
of TYPO3 core recommended `Build/` structure.

Co-authored-by: Stefan Bürk <stefan.buerk@impactmedia.de>
2022-10-24 18:26:02 +02:00
Oliver Klee
5a5d900c27
[TASK] Add .gitignore entry for JetBrains Fleet editor (#642)
JetBrains created a new product named "Fleet" as
lightweight editor. This tool tends to write it's
config files to `.fleet/` folders, like all of the
IntellJ based IDE's like PHPStorm uses the `.idea`
folder.

This change adds this config folder to `.gitignore`
to avoid adding this folder to a patch if Fleet
is used to create a patch.
2022-10-16 17:47:04 +02:00
jpmschuler
518bae014e
[TASK] Move npm tools and config to default places (#445)
- Move npm tools and config to default places
- Remove now unnecessary config file parameter from npm scripts
- editorconfig and eslint config contradict, adapt editorconfig
- switch JS indent linting to TYPO3 coding standard of 2 spaces
- adapt composer scripts for new npm location
2022-05-18 17:17:45 +02:00
Oliver Klee
2e31910c61
[FEATURE] Use Coveralls for the code coverage (#425)
Fixes #345
Closes #400
2022-04-15 18:47:18 +02:00
Oliver Klee
fcd0f60d1b
[CLEANUP] Sort the entries in the .gitignore (#428) 2022-04-13 16:13:48 +02:00
Tobias Gaertner
cc62f32a36
[BUGFIX] Fix some .gitignore entries (#375)
- `.php_cs.cache` file was renamed to `.php-cs-fixer.cache`
- `.phpunit.result.cache` missing in `.gitignore`
2022-02-04 15:09:17 +01:00
Łukasz Uznański
9bf78a580b
[FEATURE] Calculate code coverage (#266) 2021-10-06 16:23:35 +02:00
Łukasz Uznański
dee89c5266
[TASK] Prepare documentation rendering (#157)
Co-authored-by: Łukasz Uznański <l.uznanski@macopedia.com>
2020-11-29 18:28:34 +01:00
Oliver Klee
c239eaf1c4
[CLEANUP] Sort the lines in the .gitignore and .gitattributes (#178) 2020-11-29 17:34:28 +01:00
Łukasz Uznański
d4ec80de29
[FEATURE] Add frontend linting (#120)
Co-authored-by: Łukasz Uznański <l.uznanski@macopedia.com>
Co-authored-by: Oliver Klee <typo3-coding@oliverklee.de>
2020-10-31 15:04:44 +01:00
Oliver Klee
3401e32a84
[FEATURE] Add PHP-CS-Fixer (#53)
Also run the fixer on all classes and tests.
2019-08-12 17:25:59 +02:00
Oliver Klee
1c82c6d3a2
[FEATURE] Add support for TYPO3 9.6 (#48) 2019-08-12 15:41:55 +02:00
Oliver Klee
1c36c57a52
[BUGFIX] Add .php_cs.cache to the .gitignore (#33)
[ci skip]
2018-10-13 23:05:01 +02:00
Oliver Klee
fa5740c3cc [TASK] Configure Composer caching and Xdebug 2018-01-10 22:23:45 +01:00
Oliver Klee
15dc45eca7 [FEATURE] Allow stand-alone tests 2017-05-05 18:00:40 +02:00
Oliver Klee
35e377ca6e [TASK] Add documentation directories to the .gitignore. 2013-11-01 19:55:30 +01:00
Oliver Klee
19c86335a5 [CLEANUP] Update .gitignore. 2013-11-01 19:51:34 +01:00
Oliver Klee
2ab4fe7610 Initial commit 2013-11-01 11:45:05 -07:00