diff --git a/.github/workflows/phpunit.yml b/.github/workflows/phpunit.yml index c39cda79c..5f22a2e58 100644 --- a/.github/workflows/phpunit.yml +++ b/.github/workflows/phpunit.yml @@ -26,7 +26,7 @@ jobs: stability: 'stable' # Minimum supported dependencies with the latest supported PHP version - - php: '8.0' + - php: '8.2' dependencies: lowest symfony: '*' stability: 'stable' @@ -47,20 +47,20 @@ jobs: symfony: '5.3.*' stability: 'stable' - # Test Symfony 5.4 dev version - - php: '7.4' + # Test Symfony 6.4 dev version + - php: '8.2' dependencies: highest - symfony: '5.4.*' + symfony: '6.4.*' stability: 'dev' - # Test Symfony 6.0 dev version - - php: '8.0' + # Test Symfony 7.0 dev version + - php: '8.2' dependencies: highest - symfony: '6.0.*' + symfony: '7.0.*' stability: 'dev' steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Configure coverage driver id: coverage @@ -77,13 +77,13 @@ jobs: if: matrix.symfony != '*' run: | composer global config --no-plugins allow-plugins.symfony/flex true - composer global require --no-interaction --no-progress symfony/flex:^1.11 + composer global require --no-interaction --no-progress symfony/flex composer config extra.symfony.require ${{ matrix.symfony }} - - name: Remove non-compatible dependencies with Symfony 6 - if: matrix.symfony == '6.0.*' + - name: Remove non-compatible dependencies with Symfony 7 + if: matrix.symfony == '7.0.*' run: | - composer remove enqueue/enqueue-bundle --dev --no-update + composer remove enqueue/enqueue-bundle symfony/templating --dev --no-update - name: Set minimum-stability run: composer config minimum-stability ${{ matrix.stability }} diff --git a/Message/Handler/WarmupCacheHandler.php b/Message/Handler/WarmupCacheHandler.php index fdbc74b7b..2354b6ece 100644 --- a/Message/Handler/WarmupCacheHandler.php +++ b/Message/Handler/WarmupCacheHandler.php @@ -14,14 +14,13 @@ use Liip\ImagineBundle\Imagine\Filter\FilterManager; use Liip\ImagineBundle\Message\WarmupCache; use Liip\ImagineBundle\Service\FilterService; -use Symfony\Component\Messenger\Handler\MessageHandlerInterface; /** * Listen to WarmupCache messages and prepare the cache for those images. * * @experimental */ -class WarmupCacheHandler implements MessageHandlerInterface +class WarmupCacheHandler { /** @var FilterManager */ private $filterManager; diff --git a/Tests/Binary/Loader/FlysystemLoaderTest.php b/Tests/Binary/Loader/FlysystemLoaderTest.php index a4db57249..cb93d8462 100644 --- a/Tests/Binary/Loader/FlysystemLoaderTest.php +++ b/Tests/Binary/Loader/FlysystemLoaderTest.php @@ -21,8 +21,6 @@ use Symfony\Component\Mime\MimeTypes; /** - * @requires PHP 5.4 - * * @covers \Liip\ImagineBundle\Binary\Loader\FlysystemLoader */ class FlysystemLoaderTest extends AbstractTest diff --git a/Tests/Binary/Loader/FlysystemV2LoaderTest.php b/Tests/Binary/Loader/FlysystemV2LoaderTest.php index 38eb34b30..1da11b0d3 100644 --- a/Tests/Binary/Loader/FlysystemV2LoaderTest.php +++ b/Tests/Binary/Loader/FlysystemV2LoaderTest.php @@ -21,8 +21,6 @@ use Symfony\Component\Mime\MimeTypes; /** - * @requires PHP 7.2 - * * @covers \Liip\ImagineBundle\Binary\Loader\FlysystemV2Loader */ class FlysystemV2LoaderTest extends AbstractTest diff --git a/Tests/Imagine/Cache/Resolver/FlysystemV2ResolverTest.php b/Tests/Imagine/Cache/Resolver/FlysystemV2ResolverTest.php index c6955658c..9943beade 100644 --- a/Tests/Imagine/Cache/Resolver/FlysystemV2ResolverTest.php +++ b/Tests/Imagine/Cache/Resolver/FlysystemV2ResolverTest.php @@ -21,8 +21,6 @@ use Symfony\Component\Routing\RequestContext; /** - * @requires PHP 7.2 - * * @covers \Liip\ImagineBundle\Imagine\Cache\Resolver\FlysystemV2Resolver */ class FlysystemV2ResolverTest extends AbstractTest diff --git a/Tests/Message/Handler/WarmupCacheHandlerTest.php b/Tests/Message/Handler/WarmupCacheHandlerTest.php index 49ac3ef8b..29779a2b7 100644 --- a/Tests/Message/Handler/WarmupCacheHandlerTest.php +++ b/Tests/Message/Handler/WarmupCacheHandlerTest.php @@ -19,12 +19,9 @@ use Liip\ImagineBundle\Message\WarmupCache; use Liip\ImagineBundle\Service\FilterService; use Liip\ImagineBundle\Tests\Functional\AbstractWebTestCase; -use Symfony\Component\Messenger\Handler\MessageHandlerInterface; use Symfony\Component\Messenger\MessageBusInterface; /** - * @requires PHP 7.1 - * * @covers \Liip\ImagineBundle\Message\Handler\WarmupCacheHandler */ class WarmupCacheHandlerTest extends AbstractWebTestCase @@ -36,13 +33,6 @@ protected function setUp(): void } } - public function testShouldImplementMessageHandlerInterface(): void - { - $rc = new \ReflectionClass(WarmupCacheHandler::class); - - $this->assertTrue($rc->implementsInterface(MessageHandlerInterface::class)); - } - public function testCouldBeConstructedWithExpectedArguments(): void { static::createClient(); diff --git a/Tests/Templating/AbstractFilterTest.php b/Tests/Templating/AbstractFilterTest.php index d23973ea5..f671aa9be 100644 --- a/Tests/Templating/AbstractFilterTest.php +++ b/Tests/Templating/AbstractFilterTest.php @@ -15,9 +15,17 @@ use Liip\ImagineBundle\Templating\FilterExtension; use Liip\ImagineBundle\Templating\Helper\FilterHelper; use Liip\ImagineBundle\Tests\AbstractTest; +use Symfony\Component\Templating\Helper\Helper; abstract class AbstractFilterTest extends AbstractTest { + public static function setUpBeforeClass(): void + { + if (!class_exists(Helper::class)) { + static::markTestSkipped('Test requires deprecated symfony/templating component'); + } + } + public function testCanBeConstructed(): void { $this->createTemplatingMock(); diff --git a/composer.json b/composer.json index e66af07ea..e5f2c9954 100644 --- a/composer.json +++ b/composer.json @@ -3,7 +3,7 @@ "type": "symfony-bundle", "description": "This bundle provides an image manipulation abstraction toolkit for Symfony-based projects.", "keywords": [ "imagine", "image", "manipulation", "pictures", "photos", "transformation", "bundle", "symfony", "liip" ], - "homepage": "http://liip.ch", + "homepage": "https://www.liip.ch", "license": "MIT", "authors": [ { @@ -21,18 +21,18 @@ "php": "^7.2|^8.0", "ext-mbstring": "*", "imagine/imagine": "^1.3.2", - "symfony/filesystem": "^3.4|^4.4|^5.3|^6.0", - "symfony/finder": "^3.4|^4.4|^5.3|^6.0", - "symfony/framework-bundle": "^3.4.23|^4.4|^5.3|^6.0", - "symfony/mime": "^4.4|^5.3|^6.0", - "symfony/options-resolver": "^3.4|^4.4|^5.3|^6.0", - "symfony/process": "^3.4|^4.4|^5.3|^6.0", + "symfony/filesystem": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/finder": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/framework-bundle": "^3.4.23|^4.4|^5.3|^6.0|^7.0", + "symfony/mime": "^4.4|^5.3|^6.0|^7.0", + "symfony/options-resolver": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/process": "^3.4|^4.4|^5.3|^6.0|^7.0", "twig/twig": "^1.44|^2.9|^3.0" }, "require-dev": { "ext-gd": "*", "amazonwebservices/aws-sdk-for-php": "^1.0", - "aws/aws-sdk-php": "^2.4", + "aws/aws-sdk-php": "^2.4|^3.0", "doctrine/cache": "^1.11|^2.0", "doctrine/persistence": "^1.3|^2.0", "enqueue/enqueue-bundle": "^0.9|^0.10", @@ -40,16 +40,16 @@ "phpstan/phpstan": "^1.10.0", "psr/cache": "^1.0|^2.0|^3.0", "psr/log": "^1.0", - "symfony/browser-kit": "^3.4|^4.4|^5.3|^6.0", - "symfony/cache": "^3.4|^4.4|^5.3|^6.0", - "symfony/console": "^3.4|^4.4|^5.3|^6.0", - "symfony/dependency-injection": "^3.4|^4.4|^5.3|^6.0", - "symfony/form": "^3.4|^4.4|^5.3|^6.0", - "symfony/messenger": "^4.4|^5.3|^6.0", - "symfony/phpunit-bridge": "^5.3", + "symfony/browser-kit": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/cache": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/console": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/dependency-injection": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/form": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/messenger": "^4.4|^5.3|^6.0|^7.0", + "symfony/phpunit-bridge": "^5.3|^6.0|^7.0", "symfony/templating": "^3.4|^4.4|^5.3|^6.0", - "symfony/validator": "^3.4|^4.4|^5.3|^6.0", - "symfony/yaml": "^3.4|^4.4|^5.3|^6.0" + "symfony/validator": "^3.4|^4.4|^5.3|^6.0|^7.0", + "symfony/yaml": "^3.4|^4.4|^5.3|^6.0|^7.0" }, "suggest": { "ext-exif": "required to read EXIF metadata from images",