Upgrade 1-11.38

This commit is contained in:
xesmyd
2026-03-30 14:10:30 +02:00
parent f2a7e6d1fc
commit ac648ef29d
24665 changed files with 69682 additions and 2205004 deletions
@@ -11,10 +11,11 @@
namespace Symfony\Bundle\FrameworkBundle\Tests\DependencyInjection;
use PHPUnit\Framework\TestCase;
use Symfony\Bundle\FrameworkBundle\DependencyInjection\Configuration;
use Symfony\Component\Config\Definition\Processor;
class ConfigurationTest extends \PHPUnit_Framework_TestCase
class ConfigurationTest extends TestCase
{
public function testDefaultConfig()
{
@@ -92,6 +93,7 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
{
$processor = new Processor();
$configuration = new Configuration(true);
$processor->processConfiguration($configuration, array(
array(
'secret' => 's3cr3t',
@@ -107,6 +109,8 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
$config = $processor->processConfiguration($configuration, array(array('assets' => null)));
$defaultConfig = array(
'enabled' => true,
'version_strategy' => null,
'version' => null,
'version_format' => '%%s?%%s',
'base_path' => '',
@@ -117,6 +121,51 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
$this->assertEquals($defaultConfig, $config['assets']);
}
/**
* @expectedException \Symfony\Component\Config\Definition\Exception\InvalidConfigurationException
* @expectedExceptionMessage You cannot use both "version_strategy" and "version" at the same time under "assets".
*/
public function testInvalidVersionStrategy()
{
$processor = new Processor();
$configuration = new Configuration(true);
$processor->processConfiguration($configuration, array(
array(
'assets' => array(
'base_urls' => '//example.com',
'version' => 1,
'version_strategy' => 'foo',
),
),
));
}
/**
* @expectedException \Symfony\Component\Config\Definition\Exception\InvalidConfigurationException
* @expectedExceptionMessage You cannot use both "version_strategy" and "version" at the same time under "assets" packages.
*/
public function testInvalidPackageVersionStrategy()
{
$processor = new Processor();
$configuration = new Configuration(true);
$processor->processConfiguration($configuration, array(
array(
'assets' => array(
'base_urls' => '//example.com',
'version' => 1,
'packages' => array(
'foo' => array(
'base_urls' => '//example.com',
'version' => 1,
'version_strategy' => 'foo',
),
),
),
),
));
}
protected static function getBundleDefaultConfig()
{
return array(
@@ -146,6 +195,10 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
'only_master_requests' => false,
'dsn' => 'file:%kernel.cache_dir%/profiler',
'collect' => true,
'matcher' => array(
'enabled' => false,
'ips' => array(),
),
),
'translator' => array(
'enabled' => false,
@@ -161,9 +214,10 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
'strict_email' => false,
),
'annotations' => array(
'cache' => 'file',
'cache' => 'php_array',
'file_cache_dir' => '%kernel.cache_dir%/annotations',
'debug' => true,
'enabled' => true,
),
'serializer' => array(
'enabled' => false,
@@ -176,6 +230,55 @@ class ConfigurationTest extends \PHPUnit_Framework_TestCase
'property_info' => array(
'enabled' => false,
),
'router' => array(
'enabled' => false,
'http_port' => 80,
'https_port' => 443,
'strict_requirements' => true,
),
'session' => array(
'enabled' => false,
'storage_id' => 'session.storage.native',
'handler_id' => 'session.handler.native_file',
'cookie_httponly' => true,
'gc_probability' => 1,
'save_path' => '%kernel.cache_dir%/sessions',
'metadata_update_threshold' => '0',
),
'request' => array(
'enabled' => false,
'formats' => array(),
),
'templating' => array(
'enabled' => false,
'hinclude_default_template' => null,
'form' => array(
'resources' => array('FrameworkBundle:Form'),
),
'engines' => array(),
'loaders' => array(),
),
'assets' => array(
'enabled' => false,
'version_strategy' => null,
'version' => null,
'version_format' => '%%s?%%s',
'base_path' => '',
'base_urls' => array(),
'packages' => array(),
),
'cache' => array(
'pools' => array(),
'app' => 'cache.adapter.filesystem',
'system' => 'cache.adapter.system',
'directory' => '%kernel.cache_dir%/pools',
'default_redis_provider' => 'redis://localhost',
),
'workflows' => array(),
'php_errors' => array(
'log' => true,
'throw' => true,
),
);
}
}