Skip to content

Commit 7b41875

Browse files
Merge branch '7.1' into 7.2
* 7.1: [Process] minor fix [Process] Fix finding executables independently of open_basedir [HttpKernel] Skip logging uncaught exceptions in ErrorHandler, assume $kernel->terminateWithException() will do it [Serializer] Fix for method named `get()` [Notifier][TurboSMS] Process partial accepted response from transport parse empty sequence elements as null [HttpClient] Fix setting CURLMOPT_MAXCONNECTS throw a meaningful exception when parsing dotenv files with BOM [FrameworkBundle] Fix schema & finish incomplete tests for lock & semaphore config [Cache] Fix RedisSentinel params types [FrameworkBundle] Fix service reset between tests [Uid][Serializer][Validator] Mention RFC 9562 make sure temp files can be cleaned up on Windows
2 parents f91514d + 6ce42d9 commit 7b41875

File tree

38 files changed

+352
-28
lines changed

38 files changed

+352
-28
lines changed

.github/workflows/integration-tests.yml

Lines changed: 9 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -122,12 +122,19 @@ jobs:
122122
image: dunglas/frankenphp:1.1.0
123123
ports:
124124
- 80:80
125+
- 8681:81
126+
- 8682:82
127+
- 8683:83
128+
- 8684:84
125129
volumes:
126130
- ${{ github.workspace }}:/symfony
127131
env:
128-
SERVER_NAME: 'http://localhost'
132+
SERVER_NAME: 'http://localhost http://localhost:81 http://localhost:82 http://localhost:83 http://localhost:84'
129133
CADDY_SERVER_EXTRA_DIRECTIVES: |
130-
root * /symfony/src/Symfony/Component/HttpFoundation/Tests/Fixtures/response-functional/
134+
route /http-client* {
135+
root * /symfony/src/Symfony/Component/HttpClient/Tests/Fixtures/response-functional/
136+
php_server
137+
}
131138
132139
steps:
133140
- name: Checkout

src/Symfony/Bundle/FrameworkBundle/Test/KernelTestCase.php

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -121,6 +121,11 @@ protected static function ensureKernelShutdown()
121121
static::$kernel->shutdown();
122122
static::$booted = false;
123123

124+
if ($container->has('services_resetter')) {
125+
// Instantiate the service because Container::reset() only resets services that have been used
126+
$container->get('services_resetter');
127+
}
128+
124129
if ($container instanceof ResetInterface) {
125130
$container->reset();
126131
}
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
$container->loadFromExtension('framework', [
4+
'annotations' => false,
5+
'http_method_override' => false,
6+
'handle_all_throwables' => true,
7+
'php_errors' => ['log' => true],
8+
'lock' => null,
9+
]);
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?php
2+
3+
$container->setParameter('env(REDIS_DSN)', 'redis://paas.com');
4+
5+
$container->loadFromExtension('framework', [
6+
'annotations' => false,
7+
'http_method_override' => false,
8+
'handle_all_throwables' => true,
9+
'php_errors' => ['log' => true],
10+
'lock' => [
11+
'foo' => 'semaphore',
12+
'bar' => 'flock',
13+
'baz' => ['semaphore', 'flock'],
14+
'qux' => '%env(REDIS_DSN)%',
15+
],
16+
]);
Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
<?php
2+
3+
$container->loadFromExtension('framework', [
4+
'annotations' => false,
5+
'http_method_override' => false,
6+
'handle_all_throwables' => true,
7+
'php_errors' => ['log' => true],
8+
'semaphore' => 'redis://localhost',
9+
]);
Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
<?php
2+
3+
$container->setParameter('env(REDIS_DSN)', 'redis://paas.com');
4+
5+
$container->loadFromExtension('framework', [
6+
'annotations' => false,
7+
'http_method_override' => false,
8+
'handle_all_throwables' => true,
9+
'php_errors' => ['log' => true],
10+
'semaphore' => [
11+
'foo' => 'redis://paas.com',
12+
'qux' => '%env(REDIS_DSN)%',
13+
],
14+
]);

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/xml/lock.xml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
<framework:config http-method-override="false" handle-all-throwables="true">
99
<framework:annotations enabled="false" />
1010
<framework:php-errors log="true" />
11-
<framework:lock/>
11+
<framework:lock>
12+
<framework:resource>semaphore</framework:resource>
13+
</framework:lock>
1214
</framework:config>
1315
</container>

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/xml/lock_named.xml

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@
55
xsi:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd
66
http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd">
77

8-
98
<parameters>
109
<parameter key="env(REDIS_URL)">redis://paas.com</parameter>
1110
</parameters>
@@ -18,7 +17,7 @@
1817
<framework:resource name="bar">flock</framework:resource>
1918
<framework:resource name="baz">semaphore</framework:resource>
2019
<framework:resource name="baz">flock</framework:resource>
21-
<framework:resource name="qux">%env(REDIS_URL)%</framework:resource>
20+
<framework:resource name="qux">%env(REDIS_DSN)%</framework:resource>
2221
</framework:lock>
2322
</framework:config>
2423
</container>

src/Symfony/Bundle/FrameworkBundle/Tests/DependencyInjection/Fixtures/xml/semaphore.xml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
<framework:config http-method-override="false" handle-all-throwables="true">
99
<framework:annotations enabled="false" />
1010
<framework:php-errors log="true" />
11-
<framework:semaphore/>
11+
<framework:semaphore>
12+
<framework:resource>redis://localhost</framework:resource>
13+
</framework:semaphore>
1214
</framework:config>
1315
</container>
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
<?xml version="1.0" ?>
2+
<container xmlns="http://symfony.com/schema/dic/services"
3+
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4+
xmlns:framework="http://symfony.com/schema/dic/symfony"
5+
xsi:schemaLocation="http://symfony.com/schema/dic/services https://symfony.com/schema/dic/services/services-1.0.xsd
6+
http://symfony.com/schema/dic/symfony https://symfony.com/schema/dic/symfony/symfony-1.0.xsd">
7+
8+
<framework:config http-method-override="false" handle-all-throwables="true">
9+
<framework:annotations enabled="false" />
10+
<framework:php-errors log="true" />
11+
<framework:semaphore>
12+
<framework:resource name="foo">redis://paas.com</framework:resource>
13+
<framework:resource name="qux">%env(REDIS_DSN)%</framework:resource>
14+
</framework:semaphore>
15+
</framework:config>
16+
</container>

0 commit comments

Comments
 (0)