From 57e4d9ee9628aba119a1166390e9c427c6dc00fa Mon Sep 17 00:00:00 2001 From: Thomas Calvet Date: Fri, 23 Dec 2022 17:13:48 +0100 Subject: [PATCH] symfony/phpunit-bridge: set umask(0000) when debug is true --- symfony/phpunit-bridge/3.3/tests/bootstrap.php | 4 ++++ symfony/phpunit-bridge/4.1/tests/bootstrap.php | 4 ++++ symfony/phpunit-bridge/4.3/tests/bootstrap.php | 4 ++++ symfony/phpunit-bridge/5.1/tests/bootstrap.php | 4 ++++ symfony/phpunit-bridge/5.3/tests/bootstrap.php | 4 ++++ 5 files changed, 20 insertions(+) diff --git a/symfony/phpunit-bridge/3.3/tests/bootstrap.php b/symfony/phpunit-bridge/3.3/tests/bootstrap.php index 469dccee..3181151d 100644 --- a/symfony/phpunit-bridge/3.3/tests/bootstrap.php +++ b/symfony/phpunit-bridge/3.3/tests/bootstrap.php @@ -9,3 +9,7 @@ if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) { } elseif (method_exists(Dotenv::class, 'bootEnv')) { (new Dotenv())->bootEnv(dirname(__DIR__).'/.env'); } + +if ($_SERVER['APP_DEBUG']) { + umask(0000); +} diff --git a/symfony/phpunit-bridge/4.1/tests/bootstrap.php b/symfony/phpunit-bridge/4.1/tests/bootstrap.php index 469dccee..3181151d 100644 --- a/symfony/phpunit-bridge/4.1/tests/bootstrap.php +++ b/symfony/phpunit-bridge/4.1/tests/bootstrap.php @@ -9,3 +9,7 @@ if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) { } elseif (method_exists(Dotenv::class, 'bootEnv')) { (new Dotenv())->bootEnv(dirname(__DIR__).'/.env'); } + +if ($_SERVER['APP_DEBUG']) { + umask(0000); +} diff --git a/symfony/phpunit-bridge/4.3/tests/bootstrap.php b/symfony/phpunit-bridge/4.3/tests/bootstrap.php index 469dccee..3181151d 100644 --- a/symfony/phpunit-bridge/4.3/tests/bootstrap.php +++ b/symfony/phpunit-bridge/4.3/tests/bootstrap.php @@ -9,3 +9,7 @@ if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) { } elseif (method_exists(Dotenv::class, 'bootEnv')) { (new Dotenv())->bootEnv(dirname(__DIR__).'/.env'); } + +if ($_SERVER['APP_DEBUG']) { + umask(0000); +} diff --git a/symfony/phpunit-bridge/5.1/tests/bootstrap.php b/symfony/phpunit-bridge/5.1/tests/bootstrap.php index 469dccee..3181151d 100644 --- a/symfony/phpunit-bridge/5.1/tests/bootstrap.php +++ b/symfony/phpunit-bridge/5.1/tests/bootstrap.php @@ -9,3 +9,7 @@ if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) { } elseif (method_exists(Dotenv::class, 'bootEnv')) { (new Dotenv())->bootEnv(dirname(__DIR__).'/.env'); } + +if ($_SERVER['APP_DEBUG']) { + umask(0000); +} diff --git a/symfony/phpunit-bridge/5.3/tests/bootstrap.php b/symfony/phpunit-bridge/5.3/tests/bootstrap.php index 469dccee..3181151d 100644 --- a/symfony/phpunit-bridge/5.3/tests/bootstrap.php +++ b/symfony/phpunit-bridge/5.3/tests/bootstrap.php @@ -9,3 +9,7 @@ if (file_exists(dirname(__DIR__).'/config/bootstrap.php')) { } elseif (method_exists(Dotenv::class, 'bootEnv')) { (new Dotenv())->bootEnv(dirname(__DIR__).'/.env'); } + +if ($_SERVER['APP_DEBUG']) { + umask(0000); +}