From e06d0bb64fff1bd0d8c1f184c593762eaa956ff7 Mon Sep 17 00:00:00 2001 From: Sergei Morozov Date: Fri, 25 Sep 2020 17:53:20 -0700 Subject: [PATCH] Fix ExceptionTest::testConnectionExceptionSqLite() on macOS --- tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php b/tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php index f5136c66c47..338d3a7aee4 100644 --- a/tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php +++ b/tests/Doctrine/Tests/DBAL/Functional/ExceptionTest.php @@ -29,6 +29,7 @@ use function version_compare; use const PHP_OS; +use const PHP_OS_FAMILY; class ExceptionTest extends DbalFunctionalTestCase { @@ -303,7 +304,7 @@ public function testConnectionExceptionSqLite(): void } // mode 0 is considered read-only on Windows - $mode = PHP_OS === 'Linux' ? 0444 : 0000; + $mode = PHP_OS_FAMILY === 'Windows' ? 0000 : 0444; $filename = sprintf('%s/%s', sys_get_temp_dir(), 'doctrine_failed_connection_' . $mode . '.db');