Skip to content

Commit

Permalink
chore: CD-327361 Added TYPO3 12 support, removed some deprecations an…
Browse files Browse the repository at this point in the history
…d fixed code-style
  • Loading branch information
sourcesoldier committed Sep 2, 2024
1 parent 84cdccd commit 67de09b
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 19 deletions.
6 changes: 4 additions & 2 deletions .code-quality/phpstan.neon
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,11 @@ parameters:
paths:
- "../Classes/"

ignoreErrors:
- identifier: missingType.iterableValue
- identifier: missingType.generics

inferPrivatePropertyTypeFromConstructor: true
checkMissingIterableValueType: false
checkGenericClassInNonGenericObjectType: false

services:
-
Expand Down
2 changes: 0 additions & 2 deletions .code-quality/rector.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,6 @@
use Rector\CodeQuality\Rector\Identical\FlipTypeControlToUseExclusiveTypeRector;
use Rector\Config\RectorConfig;
use Rector\DeadCode\Rector\Property\RemoveUnusedPrivatePropertyRector;
use Rector\EarlyReturn\Rector\If_\ChangeAndIfToEarlyReturnRector;
use Rector\Set\ValueObject\SetList;
use Rector\PHPUnit\CodeQuality\Rector\Class_\YieldDataProviderRector;
use Rector\PHPUnit\Set\PHPUnitSetList;
Expand Down Expand Up @@ -33,7 +32,6 @@
PHPUnitSetList::PHPUNIT_CODE_QUALITY
])
->withSkip([
ChangeAndIfToEarlyReturnRector::class,
TypedPropertyFromStrictSetUpRector::class,
AddMethodCallBasedStrictParamTypeRector::class,
FlipTypeControlToUseExclusiveTypeRector::class,
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
strategy:
fail-fast: false
matrix:
typo3: [ ^11.5, ^12.4 ]
typo3: [ ^12.4 ]
php: [ '8.1', '8.2', '8.3' ]
mysql: [ '5.7' ]

Expand Down
2 changes: 1 addition & 1 deletion Configuration/Services.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,4 @@ services:
AOE\HappyFeet\Domain\Repository\FootnoteRepository:

AOE\HappyFeet\Typo3\Hook\HappyFeetLinkWizzard:
public: true
public: true
4 changes: 2 additions & 2 deletions Tests/Unit/Typo3/Hooks/TcemainTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,12 +47,12 @@ class TcemainTest extends UnitTestCase
/**
* @var DataHandler
*/
protected $dataHandler;
protected MockObject $dataHandler;

/**
* @var FootnoteRepository|MockObject
*/
protected $footnoteRepository;
protected MockObject $footnoteRepository;

protected function setUp(): void
{
Expand Down
6 changes: 2 additions & 4 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@
"require": {
"php": ">8.0",
"ext-pdo": "*",
"typo3/cms-core": "^11.5 || ^12.4",
"typo3/cms-core": "^12.4",
"typo3/cms-extbase": "*"
},
"require-dev": {
Expand Down Expand Up @@ -82,11 +82,9 @@
"./.Build/bin/phpstan analyse -c .code-quality/phpstan.neon --memory-limit=1G --generate-baseline"
],
"code-compatibility": [
"[ -e ./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs ] || composer install",
"[ -e ./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs ] || composer update",
"[ -d ./reports/php_checkstyle ] || mkdir -p reports/php_checkstyle/",
"./.code-quality/configure-checkstyle.sh",
"./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs -d memory_limit=1G --standard=PHPCompatibility --colors --ignore=*/.Build/* -p . --runtime-set testVersion 7.4",
"./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs -d memory_limit=1G --standard=PHPCompatibility --colors --ignore=*/.Build/* -p . --runtime-set testVersion 8.0",
"./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs -d memory_limit=1G --standard=PHPCompatibility --colors --ignore=*/.Build/* -p . --runtime-set testVersion 8.1",
"./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs -d memory_limit=1G --standard=PHPCompatibility --colors --ignore=*/.Build/* -p . --runtime-set testVersion 8.2",
"./.Build/vendor/symplify/easy-coding-standard/vendor/squizlabs/php_codesniffer/bin/phpcs -d memory_limit=1G --standard=PHPCompatibility --colors --ignore=*/.Build/* -p . --runtime-set testVersion 8.3"
Expand Down
4 changes: 2 additions & 2 deletions ext_emconf.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
'clearCacheOnLoad' => 0,
'lockType' => '',
'author_company' => 'AOE GmbH',
'version' => '11.3.5',
'version' => '12.0.0',
'constraints' => [
'depends' => [
'typo3' => '11.5.0-11.5.99',
'typo3' => '12.4.0-12.4.99',
],
'conflicts' => [],
'suggests' => [],
Expand Down
4 changes: 0 additions & 4 deletions ext_localconf.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

use AOE\HappyFeet\Typo3\Hook\LinkHandler;
use AOE\HappyFeet\Typo3\Hook\LinkRenderer;
use AOE\HappyFeet\Typo3\Hook\Tcemain;
use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;

defined('TYPO3') or die();
Expand All @@ -15,8 +14,5 @@
"@import 'EXT:happy_feet/Configuration/TsConfig/Page/TceMain.tsconfig'"
);

#$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['t3lib/class.t3lib_tcemain.php']['processDatamapClass']['happy_feet'] =
# Tcemain::class;

$GLOBALS['TYPO3_CONF_VARS']['FE']['typolinkBuilder']['happy_feet'] = LinkRenderer::class;
$GLOBALS['TYPO3_CONF_VARS']['SYS']['linkHandler']['happy_feet'] = LinkHandler::class;
2 changes: 1 addition & 1 deletion ext_tables.php
Original file line number Diff line number Diff line change
Expand Up @@ -7,4 +7,4 @@
'lower' => mktime(0, 0, 0, date('m') - 1, date('d'), date('Y'))
];

\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::allowTableOnStandardPages('tx_happyfeet_domain_model_footnote');
$GLOBALS['TCA']['tx_happyfeet_domain_model_footnote']['ctrl']['security']['ignorePageTypeRestriction'] = true;

0 comments on commit 67de09b

Please sign in to comment.