diff --git a/File/UploadedFile.php b/File/UploadedFile.php index 36fd1e65c..5d5063e46 100644 --- a/File/UploadedFile.php +++ b/File/UploadedFile.php @@ -31,7 +31,7 @@ */ class UploadedFile extends File { - private $test = false; + private $test; private $originalName; private $mimeType; private $error; @@ -83,7 +83,7 @@ public function __construct(string $path, string $originalName, string $mimeType * It is extracted from the request from which the file has been uploaded. * Then it should not be considered as a safe value. * - * @return string|null The original name + * @return string The original name */ public function getClientOriginalName() { @@ -112,7 +112,7 @@ public function getClientOriginalExtension() * For a trusted mime type, use getMimeType() instead (which guesses the mime * type based on the file content). * - * @return string|null The mime type + * @return string The mime type * * @see getMimeType() */ diff --git a/Tests/Session/Storage/Handler/AbstractRedisSessionHandlerTestCase.php b/Tests/Session/Storage/Handler/AbstractRedisSessionHandlerTestCase.php index 8828be666..3f3982ff4 100644 --- a/Tests/Session/Storage/Handler/AbstractRedisSessionHandlerTestCase.php +++ b/Tests/Session/Storage/Handler/AbstractRedisSessionHandlerTestCase.php @@ -44,6 +44,11 @@ protected function setUp(): void if (!\extension_loaded('redis')) { self::markTestSkipped('Extension redis required.'); } + try { + (new \Redis())->connect(getenv('REDIS_HOST')); + } catch (\Exception $e) { + self::markTestSkipped($e->getMessage()); + } $host = getenv('REDIS_HOST') ?: 'localhost'; diff --git a/Tests/Session/Storage/Handler/PredisClusterSessionHandlerTest.php b/Tests/Session/Storage/Handler/PredisClusterSessionHandlerTest.php index 622b42da1..8926fb1a9 100644 --- a/Tests/Session/Storage/Handler/PredisClusterSessionHandlerTest.php +++ b/Tests/Session/Storage/Handler/PredisClusterSessionHandlerTest.php @@ -13,6 +13,9 @@ use Predis\Client; +/** + * @group integration + */ class PredisClusterSessionHandlerTest extends AbstractRedisSessionHandlerTestCase { protected function createRedisClient(string $host): Client diff --git a/Tests/Session/Storage/Handler/PredisSessionHandlerTest.php b/Tests/Session/Storage/Handler/PredisSessionHandlerTest.php index 5ecab116f..bb33a3d9a 100644 --- a/Tests/Session/Storage/Handler/PredisSessionHandlerTest.php +++ b/Tests/Session/Storage/Handler/PredisSessionHandlerTest.php @@ -13,6 +13,9 @@ use Predis\Client; +/** + * @group integration + */ class PredisSessionHandlerTest extends AbstractRedisSessionHandlerTestCase { protected function createRedisClient(string $host): Client diff --git a/Tests/Session/Storage/Handler/RedisArraySessionHandlerTest.php b/Tests/Session/Storage/Handler/RedisArraySessionHandlerTest.php index 3ef6cb694..c2647c35b 100644 --- a/Tests/Session/Storage/Handler/RedisArraySessionHandlerTest.php +++ b/Tests/Session/Storage/Handler/RedisArraySessionHandlerTest.php @@ -11,6 +11,9 @@ namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler; +/** + * @group integration + */ class RedisArraySessionHandlerTest extends AbstractRedisSessionHandlerTestCase { /** diff --git a/Tests/Session/Storage/Handler/RedisClusterSessionHandlerTest.php b/Tests/Session/Storage/Handler/RedisClusterSessionHandlerTest.php index 8b4cd1cdd..278b3c876 100644 --- a/Tests/Session/Storage/Handler/RedisClusterSessionHandlerTest.php +++ b/Tests/Session/Storage/Handler/RedisClusterSessionHandlerTest.php @@ -11,6 +11,9 @@ namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler; +/** + * @group integration + */ class RedisClusterSessionHandlerTest extends AbstractRedisSessionHandlerTestCase { public static function setUpBeforeClass(): void diff --git a/Tests/Session/Storage/Handler/RedisSessionHandlerTest.php b/Tests/Session/Storage/Handler/RedisSessionHandlerTest.php index 71658f072..e7fb1ca19 100644 --- a/Tests/Session/Storage/Handler/RedisSessionHandlerTest.php +++ b/Tests/Session/Storage/Handler/RedisSessionHandlerTest.php @@ -11,6 +11,9 @@ namespace Symfony\Component\HttpFoundation\Tests\Session\Storage\Handler; +/** + * @group integration + */ class RedisSessionHandlerTest extends AbstractRedisSessionHandlerTestCase { /** diff --git a/composer.json b/composer.json index efc4b9425..a8c7c24c4 100644 --- a/composer.json +++ b/composer.json @@ -16,7 +16,7 @@ } ], "require": { - "php": "^7.1.3", + "php": ">=7.1.3", "symfony/mime": "^4.3|^5.0", "symfony/polyfill-mbstring": "~1.1" },
Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.
Alternative Proxies: