lexik / LexikTranslationBundle

This Symfony bundle allow to import translation files content into the database and provide a GUI to edit translations.
MIT License
419 stars 255 forks source link

Constraint dev dependencies to compatible versions #432

Closed raziel057 closed 12 months ago

raziel057 commented 12 months ago

Add specific constraints to DEV dependencies to avoid issues when trying to run the tests.

Target doctrine\annotation ^1.13 to avoid issue as 2.x doesn't contains anymore "AnnotationRegistry::registerAutoloadNamespace" method (see https://github.com/doctrine/annotations/blob/2.0.x/UPGRADE.md):

image

Add return types in AppKernel to be compatible with SF6.3

vendor/bin/phpunit
PHPUnit 9.6.10 by Sebastian Bergmann and contributors.

Warning:       Your XML configuration validates against a deprecated schema.
Suggestion:    Migrate your XML configuration using "--migrate-configuration"!

PHP Fatal error:  Declaration of AppKernel::getCacheDir() must be compatible with Symfony\Component\HttpKernel\Kernel::getCacheDir(): string in X:\workspace-novento\LexikTranslationBundle\Tests\app\AppKernel.php on line 64

Fatal error: Declaration of AppKernel::getCacheDir() must be compatible with Symfony\Component\HttpKernel\Kernel::getCacheDir(): string in X:\workspace-novento\LexikTranslationBundle\Tests\app\AppKernel.php on line 64

Target monolog/monolog: ^2.0

vendor/bin/phpunit
PHPUnit 9.6.10 by Sebastian Bergmann and contributors.

Warning:       Your XML configuration validates against a deprecated schema.
Suggestion:    Migrate your XML configuration using "--migrate-configuration"!

PHP Fatal error:  During class fetch: Uncaught Error: Class "Monolog\Logger" not found in LexikTranslationBundle\vendor\symfony\symfony\src\Symfony\Bridge\Monolog\Processor\CompatibilityProcessor.php:17
Stack trace:
#0 LexikTranslationBundle\vendor\composer\ClassLoader.php(571): include()
#1 LexikTranslationBundle\vendor\composer\ClassLoader.php(428): Composer\Autoload\includeFile(...')

Target doctrine/cache: ^1.4 to fix errors related to removal of Doctrine\Common\Cache\ArrayCache in latest (2.x versions).

vendor/bin/phpunit
PHPUnit 9.6.10 by Sebastian Bergmann and contributors.

Warning:       Your XML configuration validates against a deprecated schema.
Suggestion:    Migrate your XML configuration using "--migrate-configuration"!

[debug] Notified event "Lexik\Bundle\TranslationBundle\EventDispatcher\Event\GetDatabaseResourcesEvent" to listener "Lexik\Bundle\TranslationBundle\EventDispatcher\GetDatabaseResourcesListener::onGetDatabaseResources".
[debug] Notified event "console.command" to listener "Symfony\Component\HttpKernel\EventListener\DebugHandlersListener::configure".
[debug] Notified event "console.terminate" to listener "Symfony\Component\Console\EventListener\ErrorListener::onConsoleTerminate".
[debug] Notified event "console.command" to listener "Symfony\Component\HttpKernel\EventListener\DebugHandlersListener::configure".
[debug] Notified event "console.terminate" to listener "Symfony\Component\Console\EventListener\ErrorListener::onConsoleTerminate".
FEEEEEEEEEEEEEE............I.........EEEEEEEEEEEEEEEEEEEEEEE..EE. 65 / 65 (100%)

Time: 00:03.997, Memory: 46.00 MB

There were 39 errors:

1) Lexik\Bundle\TranslationBundle\Tests\Unit\Repository\Document\FileRepositoryTest::testFindForLocalesAndDomains
Error: Class "Doctrine\Common\Cache\ArrayCache" not found