Drop support for core versions below 10.3 and add support for drupal 12.
https://www.drupal.org/project/block_class/issues/3590369
Support for Drupal 12:
- Core version requirements: Dropped support for versions below 10.3 and added support for 12.
- Disabled Gitlab CI job
phpstan (previous major), currently testing10.6.x, to prevent it from failing with missingLegacyHookattribute errors. - Added support for object oriented hook implementations using autowired services as described in DO-3442349. Reused most of the code from MR !80 (closed).
- Normalized file
composer.json. - Excluded file
tests/src/Kernel/BlockClassMigrationTest.phpfrom phpstan validation to prevent prompting errors for D12. - Added
declare(strict_types=1);in all PHP files and types where needed. - Added dependency injection in class
BlockClassHooksto check the current user permissions. - Refactored tested block names, ids and classes in Functional tests
BlockClassTest. - Added Kernel tests abstract class
BlockClassMigrationTestBaseto be able to conditionally support drupal migrate Kernel tests for D11 and skip on D12.