Commit 150c18e2 authored by Wouter Wolters's avatar Wouter Wolters Committed by Benni Mack
Browse files

[TASK] Upgrade php-cs-fixer to latest version v3

diff-format option has been removed. udiff is the default
now since v3.

composer u friendsofphp/php-cs-fixer composer/xdebug-handler php-cs-fixer/diff
composer req --dev friendsofphp/php-cs-fixer:^3.0

Resolves: #94856
Releases: master
Change-Id: I33470fc49b4355130e73326c85323a1848fe3562
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/70516


Tested-by: core-ci's avatarcore-ci <typo3@b13.com>
Tested-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Tested-by: Benni Mack's avatarBenni Mack <benni@typo3.org>
Reviewed-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Reviewed-by: Benni Mack's avatarBenni Mack <benni@typo3.org>
parent 8188b861
......@@ -27,6 +27,7 @@ nbproject
# Temporary files and folders
.cache
.php_cs.cache
.php-cs-fixer.cache
.sass-cache
.session
*.log
......
......@@ -18,7 +18,7 @@
filestype=commit
# non-dryrun is default
DRYRUN=""
DRYRUN_OPTIONS="--dry-run --diff --diff-format udiff"
DRYRUN_OPTIONS="--dry-run --diff"
# ----------------------
# --- automatic vars ---
......
......@@ -497,7 +497,7 @@ case ${TEST_SUITE} in
cgl)
# Active dry-run for cgl needs not "-n" but specific options
if [[ ! -z ${CGLCHECK_DRY_RUN} ]]; then
CGLCHECK_DRY_RUN="--dry-run --diff --diff-format udiff"
CGLCHECK_DRY_RUN="--dry-run --diff"
fi
setUpDockerComposeDotEnv
docker-compose run cgl_all
......
......@@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies",
"This file is @generated automatically"
],
"content-hash": "bad29e59907694c34f43022f4c42fc21",
"content-hash": "7bf31b3ea38ea5c3ec6a128d71f94230",
"packages": [
{
"name": "bacon/bacon-qr-code",
......@@ -5791,24 +5791,25 @@
},
{
"name": "composer/xdebug-handler",
"version": "1.4.5",
"version": "2.0.2",
"source": {
"type": "git",
"url": "https://github.com/composer/xdebug-handler.git",
"reference": "f28d44c286812c714741478d968104c5e604a1d4"
"reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/composer/xdebug-handler/zipball/f28d44c286812c714741478d968104c5e604a1d4",
"reference": "f28d44c286812c714741478d968104c5e604a1d4",
"url": "https://api.github.com/repos/composer/xdebug-handler/zipball/84674dd3a7575ba617f5a76d7e9e29a7d3891339",
"reference": "84674dd3a7575ba617f5a76d7e9e29a7d3891339",
"shasum": ""
},
"require": {
"php": "^5.3.2 || ^7.0 || ^8.0",
"psr/log": "^1.0"
"psr/log": "^1 || ^2 || ^3"
},
"require-dev": {
"phpunit/phpunit": "^4.8.35 || ^5.7 || 6.5 - 8"
"phpstan/phpstan": "^0.12.55",
"symfony/phpunit-bridge": "^4.2 || ^5"
},
"type": "library",
"autoload": {
......@@ -5834,7 +5835,7 @@
"support": {
"irc": "irc://irc.freenode.org/composer",
"issues": "https://github.com/composer/xdebug-handler/issues",
"source": "https://github.com/composer/xdebug-handler/tree/1.4.5"
"source": "https://github.com/composer/xdebug-handler/tree/2.0.2"
},
"funding": [
{
......@@ -5850,89 +5851,68 @@
"type": "tidelift"
}
],
"time": "2020-11-13T08:04:11+00:00"
"time": "2021-07-31T17:03:58+00:00"
},
{
"name": "friendsofphp/php-cs-fixer",
"version": "v2.19.0",
"version": "v3.0.2",
"source": {
"type": "git",
"url": "https://github.com/FriendsOfPHP/PHP-CS-Fixer.git",
"reference": "d5b8a9d852b292c2f8a035200fa6844b1f82300b"
"reference": "990b979379502feb7f393d6c9aa36cc9b9765f24"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/d5b8a9d852b292c2f8a035200fa6844b1f82300b",
"reference": "d5b8a9d852b292c2f8a035200fa6844b1f82300b",
"url": "https://api.github.com/repos/FriendsOfPHP/PHP-CS-Fixer/zipball/990b979379502feb7f393d6c9aa36cc9b9765f24",
"reference": "990b979379502feb7f393d6c9aa36cc9b9765f24",
"shasum": ""
},
"require": {
"composer/semver": "^1.4 || ^2.0 || ^3.0",
"composer/xdebug-handler": "^1.2 || ^2.0",
"doctrine/annotations": "^1.2",
"composer/semver": "^3.2",
"composer/xdebug-handler": "^2.0",
"doctrine/annotations": "^1.12",
"ext-json": "*",
"ext-tokenizer": "*",
"php": "^5.6 || ^7.0 || ^8.0",
"php-cs-fixer/diff": "^1.3",
"symfony/console": "^3.4.43 || ^4.1.6 || ^5.0",
"symfony/event-dispatcher": "^3.0 || ^4.0 || ^5.0",
"symfony/filesystem": "^3.0 || ^4.0 || ^5.0",
"symfony/finder": "^3.0 || ^4.0 || ^5.0",
"symfony/options-resolver": "^3.0 || ^4.0 || ^5.0",
"symfony/polyfill-php70": "^1.0",
"symfony/polyfill-php72": "^1.4",
"symfony/process": "^3.0 || ^4.0 || ^5.0",
"symfony/stopwatch": "^3.0 || ^4.0 || ^5.0"
"php": "^7.1.3 || ^8.0",
"php-cs-fixer/diff": "^2.0",
"symfony/console": "^4.4.20 || ^5.1.3",
"symfony/event-dispatcher": "^4.4.20 || ^5.0",
"symfony/filesystem": "^4.4.20 || ^5.0",
"symfony/finder": "^4.4.20 || ^5.0",
"symfony/options-resolver": "^4.4.20 || ^5.0",
"symfony/polyfill-php72": "^1.22",
"symfony/process": "^4.4.20 || ^5.0",
"symfony/stopwatch": "^4.4.20 || ^5.0"
},
"require-dev": {
"justinrainbow/json-schema": "^5.0",
"justinrainbow/json-schema": "^5.2",
"keradus/cli-executor": "^1.4",
"mikey179/vfsstream": "^1.6",
"php-coveralls/php-coveralls": "^2.4.2",
"php-cs-fixer/accessible-object": "^1.0",
"mikey179/vfsstream": "^1.6.8",
"php-coveralls/php-coveralls": "^2.4.3",
"php-cs-fixer/accessible-object": "^1.1",
"php-cs-fixer/phpunit-constraint-isidenticalstring": "^1.2",
"php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "^1.2.1",
"phpspec/prophecy": "^1.10.3",
"phpspec/prophecy-phpunit": "^1.1 || ^2.0",
"phpunit/phpunit": "^5.7.27 || ^6.5.14 || ^7.5.20 || ^8.5.13 || ^9.5",
"phpunit/phpunit": "^7.5.20 || ^8.5.14 || ^9.5",
"phpunitgoodpractices/polyfill": "^1.5",
"phpunitgoodpractices/traits": "^1.9.1",
"sanmai/phpunit-legacy-adapter": "^6.4 || ^8.2.1",
"symfony/phpunit-bridge": "^5.2.1",
"symfony/yaml": "^3.0 || ^4.0 || ^5.0"
"symfony/phpunit-bridge": "^5.2.4",
"symfony/yaml": "^4.4.20 || ^5.0"
},
"suggest": {
"ext-dom": "For handling output formats in XML",
"ext-mbstring": "For handling non-UTF8 characters.",
"php-cs-fixer/phpunit-constraint-isidenticalstring": "For IsIdenticalString constraint.",
"php-cs-fixer/phpunit-constraint-xmlmatchesxsd": "For XmlMatchesXsd constraint.",
"symfony/polyfill-mbstring": "When enabling `ext-mbstring` is not possible."
},
"bin": [
"php-cs-fixer"
],
"type": "application",
"extra": {
"branch-alias": {
"dev-master": "2.19-dev"
}
},
"autoload": {
"psr-4": {
"PhpCsFixer\\": "src/"
},
"classmap": [
"tests/Test/AbstractFixerTestCase.php",
"tests/Test/AbstractIntegrationCaseFactory.php",
"tests/Test/AbstractIntegrationTestCase.php",
"tests/Test/Assert/AssertTokensTrait.php",
"tests/Test/IntegrationCase.php",
"tests/Test/IntegrationCaseFactory.php",
"tests/Test/IntegrationCaseFactoryInterface.php",
"tests/Test/InternalIntegrationCaseFactory.php",
"tests/Test/IsIdenticalConstraint.php",
"tests/Test/TokensWithObservedTransformers.php",
"tests/TestCase.php"
]
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
......@@ -5951,7 +5931,7 @@
"description": "A tool to automatically fix PHP code style",
"support": {
"issues": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/issues",
"source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v2.19.0"
"source": "https://github.com/FriendsOfPHP/PHP-CS-Fixer/tree/v3.0.2"
},
"funding": [
{
......@@ -5959,7 +5939,7 @@
"type": "github"
}
],
"time": "2021-05-03T21:43:24+00:00"
"time": "2021-08-04T19:28:19+00:00"
},
{
"name": "friendsoftypo3/phpstan-typo3",
......@@ -6226,16 +6206,16 @@
},
{
"name": "php-cs-fixer/diff",
"version": "v1.3.1",
"version": "v2.0.2",
"source": {
"type": "git",
"url": "https://github.com/PHP-CS-Fixer/diff.git",
"reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759"
"reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/dbd31aeb251639ac0b9e7e29405c1441907f5759",
"reference": "dbd31aeb251639ac0b9e7e29405c1441907f5759",
"url": "https://api.github.com/repos/PHP-CS-Fixer/diff/zipball/29dc0d507e838c4580d018bd8b5cb412474f7ec3",
"reference": "29dc0d507e838c4580d018bd8b5cb412474f7ec3",
"shasum": ""
},
"require": {
......@@ -6263,21 +6243,18 @@
{
"name": "Kore Nordmann",
"email": "mail@kore-nordmann.de"
},
{
"name": "SpacePossum"
}
],
"description": "sebastian/diff v2 backport support for PHP5.6",
"description": "sebastian/diff v3 backport support for PHP 5.6+",
"homepage": "https://github.com/PHP-CS-Fixer",
"keywords": [
"diff"
],
"support": {
"issues": "https://github.com/PHP-CS-Fixer/diff/issues",
"source": "https://github.com/PHP-CS-Fixer/diff/tree/v1.3.1"
"source": "https://github.com/PHP-CS-Fixer/diff/tree/v2.0.2"
},
"time": "2020-10-14T08:39:05+00:00"
"time": "2020-10-14T08:32:19+00:00"
},
{
"name": "php-webdriver/webdriver",
......@@ -7975,74 +7952,6 @@
],
"time": "2021-07-21T12:38:00+00:00"
},
{
"name": "symfony/polyfill-php70",
"version": "v1.20.0",
"source": {
"type": "git",
"url": "https://github.com/symfony/polyfill-php70.git",
"reference": "5f03a781d984aae42cebd18e7912fa80f02ee644"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/symfony/polyfill-php70/zipball/5f03a781d984aae42cebd18e7912fa80f02ee644",
"reference": "5f03a781d984aae42cebd18e7912fa80f02ee644",
"shasum": ""
},
"require": {
"php": ">=7.1"
},
"type": "metapackage",
"extra": {
"branch-alias": {
"dev-main": "1.20-dev"
},
"thanks": {
"name": "symfony/polyfill",
"url": "https://github.com/symfony/polyfill"
}
},
"notification-url": "https://packagist.org/downloads/",
"license": [
"MIT"
],
"authors": [
{
"name": "Nicolas Grekas",
"email": "p@tchwork.com"
},
{
"name": "Symfony Community",
"homepage": "https://symfony.com/contributors"
}
],
"description": "Symfony polyfill backporting some PHP 7.0+ features to lower PHP versions",
"homepage": "https://symfony.com",
"keywords": [
"compatibility",
"polyfill",
"portable",
"shim"
],
"support": {
"source": "https://github.com/symfony/polyfill-php70/tree/v1.20.0"
},
"funding": [
{
"url": "https://symfony.com/sponsor",
"type": "custom"
},
{
"url": "https://github.com/fabpot",
"type": "github"
},
{
"url": "https://tidelift.com/funding/github/packagist/symfony/symfony",
"type": "tidelift"
}
],
"time": "2020-10-23T14:02:19+00:00"
},
{
"name": "symfony/process",
"version": "v5.2.1",
......
......@@ -344,7 +344,7 @@ class PageRenderer implements SingletonInterface
/**
* @var FrontendInterface
*/
protected static $cache = null;
protected static $cache;
/**
* @param string $templateFile Declare the used template file. Omit this parameter will use default template
......
......@@ -547,7 +547,7 @@ class ContentObjectRendererTest extends FunctionalTestCase
->onlyMethods(['createTotalUrlAndLinkData'])
->setConstructorArgs([$subject])
->getMock();
$pageLinkBuilder->expects($this::once())->method('createTotalUrlAndLinkData')->willReturn([
$pageLinkBuilder->expects(self::once())->method('createTotalUrlAndLinkData')->willReturn([
'url' => '/index.php?id=1',
'target' => '',
'type' => '',
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment