diff --git a/CHANGELOG.md b/CHANGELOG.md
index f1cb8328..6d2f8eb5 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,6 +1,11 @@
CHANGELOG
=========
+7.2
+---
+
+ * Add support for displaying profiles of multiple serializer instances
+
7.1
---
diff --git a/Controller/ProfilerController.php b/Controller/ProfilerController.php
index f2ee4ec9..0e0d4f89 100644
--- a/Controller/ProfilerController.php
+++ b/Controller/ProfilerController.php
@@ -99,7 +99,7 @@ public function panelAction(Request $request, string $token): Response
}
if (!$profile->hasCollector($panel)) {
- throw new NotFoundHttpException(sprintf('Panel "%s" is not available for token "%s".', $panel, $token));
+ throw new NotFoundHttpException(\sprintf('Panel "%s" is not available for token "%s".', $panel, $token));
}
return $this->renderWithCspNonces($request, $this->getTemplateManager()->getName($profile, $panel), [
@@ -162,6 +162,27 @@ public function toolbarAction(Request $request, ?string $token = null): Response
]);
}
+ /**
+ * Renders the Web Debug Toolbar stylesheet.
+ *
+ * @throws NotFoundHttpException
+ */
+ public function toolbarStylesheetAction(): Response
+ {
+ $this->denyAccessIfProfilerDisabled();
+
+ $this->cspHandler?->disableCsp();
+
+ return new Response(
+ $this->twig->render('@WebProfiler/Profiler/toolbar.css.twig'),
+ 200,
+ [
+ 'Content-Type' => 'text/css',
+ 'Cache-Control' => 'max-age=600, private',
+ ],
+ );
+ }
+
/**
* Renders the profiler search bar.
*
@@ -336,12 +357,12 @@ public function fontAction(string $fontName): Response
{
$this->denyAccessIfProfilerDisabled();
if ('JetBrainsMono' !== $fontName) {
- throw new NotFoundHttpException(sprintf('Font file "%s.woff2" not found.', $fontName));
+ throw new NotFoundHttpException(\sprintf('Font file "%s.woff2" not found.', $fontName));
}
$fontFile = \dirname(__DIR__).'/Resources/fonts/'.$fontName.'.woff2';
if (!is_file($fontFile) || !is_readable($fontFile)) {
- throw new NotFoundHttpException(sprintf('Cannot read font file "%s".', $fontFile));
+ throw new NotFoundHttpException(\sprintf('Cannot read font file "%s".', $fontFile));
}
$this->profiler?->disable();
@@ -368,7 +389,7 @@ public function openAction(Request $request): Response
$filename = $this->baseDir.\DIRECTORY_SEPARATOR.$file;
if (preg_match("'(^|[/\\\\])\.'", $file) || !is_readable($filename)) {
- throw new NotFoundHttpException(sprintf('The file "%s" cannot be opened.', $file));
+ throw new NotFoundHttpException(\sprintf('The file "%s" cannot be opened.', $file));
}
return $this->renderWithCspNonces($request, '@WebProfiler/Profiler/open.html.twig', [
@@ -383,6 +404,9 @@ protected function getTemplateManager(): TemplateManager
return $this->templateManager ??= new TemplateManager($this->profiler, $this->twig, $this->templates);
}
+ /**
+ * @throws NotFoundHttpException
+ */
private function denyAccessIfProfilerDisabled(): void
{
if (null === $this->profiler) {
diff --git a/Csp/ContentSecurityPolicyHandler.php b/Csp/ContentSecurityPolicyHandler.php
index 3ac92aba..3fca0b97 100644
--- a/Csp/ContentSecurityPolicyHandler.php
+++ b/Csp/ContentSecurityPolicyHandler.php
@@ -151,7 +151,7 @@ private function updateCspHeaders(Response $response, array $nonces = []): array
if (!\in_array('\'unsafe-inline\'', $headers[$header][$type], true)) {
$headers[$header][$type][] = '\'unsafe-inline\'';
}
- $headers[$header][$type][] = sprintf('\'nonce-%s\'', $nonces[$tokenName]);
+ $headers[$header][$type][] = \sprintf('\'nonce-%s\'', $nonces[$tokenName]);
}
}
@@ -179,7 +179,7 @@ private function generateNonce(): string
*/
private function generateCspHeader(array $directives): string
{
- return array_reduce(array_keys($directives), fn ($res, $name) => ('' !== $res ? $res.'; ' : '').sprintf('%s %s', $name, implode(' ', $directives[$name])), '');
+ return array_reduce(array_keys($directives), fn ($res, $name) => ('' !== $res ? $res.'; ' : '').\sprintf('%s %s', $name, implode(' ', $directives[$name])), '');
}
/**
diff --git a/EventListener/WebDebugToolbarListener.php b/EventListener/WebDebugToolbarListener.php
index f3e818ba..a13421e7 100644
--- a/EventListener/WebDebugToolbarListener.php
+++ b/EventListener/WebDebugToolbarListener.php
@@ -59,7 +59,7 @@ public function isEnabled(): bool
public function setMode(int $mode): void
{
if (self::DISABLED !== $mode && self::ENABLED !== $mode) {
- throw new \InvalidArgumentException(sprintf('Invalid value provided for mode, use one of "%s::DISABLED" or "%s::ENABLED".', self::class, self::class));
+ throw new \InvalidArgumentException(\sprintf('Invalid value provided for mode, use one of "%s::DISABLED" or "%s::ENABLED".', self::class, self::class));
}
$this->mode = $mode;
diff --git a/Profiler/CodeExtension.php b/Profiler/CodeExtension.php
index 1701dd1a..332a5d6c 100644
--- a/Profiler/CodeExtension.php
+++ b/Profiler/CodeExtension.php
@@ -57,18 +57,18 @@ public function abbrClass(string $class): string
$parts = explode('\\', $class);
$short = array_pop($parts);
- return sprintf('%s ', $class, $short);
+ return \sprintf('%s ', $class, $short);
}
public function abbrMethod(string $method): string
{
if (str_contains($method, '::')) {
[$class, $method] = explode('::', $method, 2);
- $result = sprintf('%s::%s()', $this->abbrClass($class), $method);
+ $result = \sprintf('%s::%s()', $this->abbrClass($class), $method);
} elseif ('Closure' === $method) {
- $result = sprintf('%1$s ', $method);
+ $result = \sprintf('%1$s ', $method);
} else {
- $result = sprintf('%1$s ()', $method);
+ $result = \sprintf('%1$s ()', $method);
}
return $result;
@@ -85,9 +85,9 @@ public function formatArgs(array $args): string
$item[1] = htmlspecialchars($item[1], \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset);
$parts = explode('\\', $item[1]);
$short = array_pop($parts);
- $formattedValue = sprintf('object (%s )', $item[1], $short);
+ $formattedValue = \sprintf('object (%s )', $item[1], $short);
} elseif ('array' === $item[0]) {
- $formattedValue = sprintf('array (%s)', \is_array($item[1]) ? $this->formatArgs($item[1]) : htmlspecialchars(var_export($item[1], true), \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset));
+ $formattedValue = \sprintf('array (%s)', \is_array($item[1]) ? $this->formatArgs($item[1]) : htmlspecialchars(var_export($item[1], true), \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset));
} elseif ('null' === $item[0]) {
$formattedValue = 'null ';
} elseif ('boolean' === $item[0]) {
@@ -100,7 +100,7 @@ public function formatArgs(array $args): string
$formattedValue = str_replace("\n", '', htmlspecialchars(var_export($item[1], true), \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset));
}
- $result[] = \is_int($key) ? $formattedValue : sprintf("'%s' => %s", htmlspecialchars($key, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $formattedValue);
+ $result[] = \is_int($key) ? $formattedValue : \sprintf("'%s' => %s", htmlspecialchars($key, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $formattedValue);
}
return implode(', ', $result);
@@ -164,7 +164,7 @@ public function formatFile(string $file, int $line, ?string $text = null): strin
if (null === $text) {
if (null !== $rel = $this->getFileRelative($file)) {
$rel = explode('/', htmlspecialchars($rel, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), 2);
- $text = sprintf('%s %s', htmlspecialchars($this->projectDir, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $rel[0], '/'.($rel[1] ?? ''));
+ $text = \sprintf('%s %s', htmlspecialchars($this->projectDir, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $rel[0], '/'.($rel[1] ?? ''));
} else {
$text = htmlspecialchars($file, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset);
}
@@ -177,7 +177,7 @@ public function formatFile(string $file, int $line, ?string $text = null): strin
}
if (false !== $link = $this->getFileLink($file, $line)) {
- return sprintf('%s ', htmlspecialchars($link, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $text);
+ return \sprintf('%s ', htmlspecialchars($link, \ENT_COMPAT | \ENT_SUBSTITUTE, $this->charset), $text);
}
return $text;
diff --git a/Profiler/TemplateManager.php b/Profiler/TemplateManager.php
index 2b3f8c2f..23b88b1d 100644
--- a/Profiler/TemplateManager.php
+++ b/Profiler/TemplateManager.php
@@ -41,7 +41,7 @@ public function getName(Profile $profile, string $panel): mixed
$templates = $this->getNames($profile);
if (!isset($templates[$panel])) {
- throw new NotFoundHttpException(sprintf('Panel "%s" is not registered in profiler or is not present in viewed profile.', $panel));
+ throw new NotFoundHttpException(\sprintf('Panel "%s" is not registered in profiler or is not present in viewed profile.', $panel));
}
return $templates[$panel];
@@ -73,7 +73,7 @@ public function getNames(Profile $profile): array
}
if (!$loader->exists($template.'.html.twig')) {
- throw new \UnexpectedValueException(sprintf('The profiler template "%s.html.twig" for data collector "%s" does not exist.', $template, $name));
+ throw new \UnexpectedValueException(\sprintf('The profiler template "%s.html.twig" for data collector "%s" does not exist.', $template, $name));
}
$templates[$name] = $template.'.html.twig';
diff --git a/Resources/config/routing/wdt.xml b/Resources/config/routing/wdt.xml
index 0f7e960c..26bbd964 100644
--- a/Resources/config/routing/wdt.xml
+++ b/Resources/config/routing/wdt.xml
@@ -4,6 +4,10 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://symfony.com/schema/routing https://symfony.com/schema/routing/routing-1.0.xsd">
+
+ web_profiler.controller.profiler::toolbarStylesheetAction
+
+
web_profiler.controller.profiler::toolbarAction
diff --git a/Resources/views/Collector/config.html.twig b/Resources/views/Collector/config.html.twig
index ca51978f..cf25892b 100644
--- a/Resources/views/Collector/config.html.twig
+++ b/Resources/views/Collector/config.html.twig
@@ -72,6 +72,14 @@
{% endset %}
{% set text %}
+ {% if symfony_version_status %}
+
+ {% endif %}
+
{% endblock %}
-{% macro render_serialize_tab(collectorData, serialize) %}
+{% macro render_serializer_tab(collector, serializer) %}
+
+
{{ serializer }} {{ collector.handledCount(serializer) }}
+
+
+ {{ _self.render_serialize_tab(collector.data(serializer), true, serializer) }}
+ {{ _self.render_serialize_tab(collector.data(serializer), false, serializer) }}
+
+ {{ _self.render_normalize_tab(collector.data(serializer), true, serializer) }}
+ {{ _self.render_normalize_tab(collector.data(serializer), false, serializer) }}
+
+ {{ _self.render_encode_tab(collector.data(serializer), true, serializer) }}
+ {{ _self.render_encode_tab(collector.data(serializer), false, serializer) }}
+
+
+
+{% endmacro %}
+
+{% macro render_serialize_tab(collectorData, serialize, serializer) %}
{% set data = serialize ? collectorData.serialize : collectorData.deserialize %}
{% set cellPrefix = serialize ? 'serialize' : 'deserialize' %}
@@ -154,12 +167,12 @@
{% for item in data %}
- {{ _self.render_data_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_context_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_normalizer_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_encoder_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_data_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_context_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_normalizer_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_encoder_cell(item, loop.index, cellPrefix, serializer) }}
{{ _self.render_time_cell(item) }}
- {{ _self.render_caller_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_caller_cell(item, loop.index, cellPrefix, serializer) }}
{% endfor %}
@@ -169,8 +182,10 @@
{% endmacro %}
-{% macro render_caller_cell(item, index, method) %}
+{% macro render_caller_cell(item, index, method, serializer) %}
{% if item.caller is defined %}
+ {% set trace_id = 'sf-trace-' ~ serializer ~ '-' ~ method ~ '-' ~ index %}
+
{% set caller = item.caller %}
{% if caller.line %}
@@ -183,10 +198,10 @@
{% else %}
{{ caller.name }}
{% endif %}
- line {{ caller.line }}
+ line {{ caller.line }}
-
+
{{ caller.file|file_excerpt(caller.line)|replace({
'#DD0000': 'var(--highlight-string)',
@@ -199,7 +214,7 @@
{% endif %}
{% endmacro %}
-{% macro render_normalize_tab(collectorData, normalize) %}
+{% macro render_normalize_tab(collectorData, normalize, serializer) %}
{% set data = normalize ? collectorData.normalize : collectorData.denormalize %}
{% set cellPrefix = normalize ? 'normalize' : 'denormalize' %}
@@ -224,11 +239,11 @@
{% for item in data %}
- {{ _self.render_data_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_context_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_normalizer_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_data_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_context_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_normalizer_cell(item, loop.index, cellPrefix, serializer) }}
{{ _self.render_time_cell(item) }}
- {{ _self.render_caller_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_caller_cell(item, loop.index, cellPrefix, serializer) }}
{% endfor %}
@@ -238,7 +253,7 @@
{% endmacro %}
-{% macro render_encode_tab(collectorData, encode) %}
+{% macro render_encode_tab(collectorData, encode, serializer) %}
{% set data = encode ? collectorData.encode : collectorData.decode %}
{% set cellPrefix = encode ? 'encode' : 'decode' %}
@@ -263,11 +278,11 @@
{% for item in data %}
- {{ _self.render_data_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_context_cell(item, loop.index, cellPrefix) }}
- {{ _self.render_encoder_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_data_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_context_cell(item, loop.index, cellPrefix, serializer) }}
+ {{ _self.render_encoder_cell(item, loop.index, cellPrefix, serializer) }}
{{ _self.render_time_cell(item) }}
- {{ _self.render_caller_cell(item, loop.index, cellPrefix) }}
+ {{ _self.render_caller_cell(item, loop.index, cellPrefix, serializer) }}
{% endfor %}
@@ -277,8 +292,8 @@
{% endmacro %}
-{% macro render_data_cell(item, index, method) %}
- {% set data_id = 'data-' ~ method ~ '-' ~ index %}
+{% macro render_data_cell(item, index, method, serializer) %}
+ {% set data_id = 'data-' ~ serializer ~ '-' ~ method ~ '-' ~ index %}
{{ item.dataType }}
@@ -290,8 +305,8 @@
{% endmacro %}
-{% macro render_context_cell(item, index, method) %}
- {% set context_id = 'context-' ~ method ~ '-' ~ index %}
+{% macro render_context_cell(item, index, method, serializer) %}
+ {% set context_id = 'context-' ~ serializer ~ '-' ~ method ~ '-' ~ index %}
{% if item.type %}
Type: {{ item.type }}
@@ -308,8 +323,8 @@
{% endmacro %}
-{% macro render_normalizer_cell(item, index, method) %}
- {% set nested_normalizers_id = 'nested-normalizers-' ~ method ~ '-' ~ index %}
+{% macro render_normalizer_cell(item, index, method, serializer) %}
+ {% set nested_normalizers_id = 'nested-normalizers-' ~ serializer ~ '-' ~ method ~ '-' ~ index %}
{% if item.normalizer is defined %}
{{ item.normalizer.class }} ({{ '%.2f'|format(item.normalizer.time * 1000) }} ms)
@@ -329,8 +344,8 @@
{% endif %}
{% endmacro %}
-{% macro render_encoder_cell(item, index, method) %}
- {% set nested_encoders_id = 'nested-encoders-' ~ method ~ '-' ~ index %}
+{% macro render_encoder_cell(item, index, method, serializer) %}
+ {% set nested_encoders_id = 'nested-encoders-' ~ serializer ~ '-' ~ method ~ '-' ~ index %}
{% if item.encoder is defined %}
{{ item.encoder.class }} ({{ '%.2f'|format(item.encoder.time * 1000) }} ms)
diff --git a/Resources/views/Collector/workflow.html.twig b/Resources/views/Collector/workflow.html.twig
index 1f882356..6f09b363 100644
--- a/Resources/views/Collector/workflow.html.twig
+++ b/Resources/views/Collector/workflow.html.twig
@@ -320,7 +320,7 @@
{% endif %}
- {{ call.duration }}ms
+ {{ '%0.2f ms'|format(call.duration) }}
{% endfor %}
diff --git a/Resources/views/Icon/symfony.svg b/Resources/views/Icon/symfony.svg
index ad38fdf9..209afed7 100644
--- a/Resources/views/Icon/symfony.svg
+++ b/Resources/views/Icon/symfony.svg
@@ -1 +1 @@
-
+
diff --git a/Resources/views/Profiler/toolbar_js.html.twig b/Resources/views/Profiler/toolbar_js.html.twig
index f6b37b37..eaf9329a 100644
--- a/Resources/views/Profiler/toolbar_js.html.twig
+++ b/Resources/views/Profiler/toolbar_js.html.twig
@@ -9,9 +9,7 @@
}) }}
-
+
{# CAUTION: the contents of this file are processed by Twig before loading
them as JavaScript source code. Always use '/*' comments instead
diff --git a/Tests/Controller/ProfilerControllerTest.php b/Tests/Controller/ProfilerControllerTest.php
index 6b6b6cf9..3933d30e 100644
--- a/Tests/Controller/ProfilerControllerTest.php
+++ b/Tests/Controller/ProfilerControllerTest.php
@@ -137,6 +137,33 @@ public function testToolbarActionWithEmptyToken($token)
$this->assertEquals(200, $response->getStatusCode());
}
+ public function testToolbarStylesheetActionWithProfilerDisabled()
+ {
+ $urlGenerator = $this->createMock(UrlGeneratorInterface::class);
+ $twig = $this->createMock(Environment::class);
+
+ $controller = new ProfilerController($urlGenerator, null, $twig, []);
+
+ $this->expectException(NotFoundHttpException::class);
+ $this->expectExceptionMessage('The profiler must be enabled.');
+
+ $controller->toolbarStylesheetAction();
+ }
+
+ public function testToolbarStylesheetAction()
+ {
+ $urlGenerator = $this->createMock(UrlGeneratorInterface::class);
+ $twig = $this->createMock(Environment::class);
+ $profiler = $this->createMock(Profiler::class);
+
+ $controller = new ProfilerController($urlGenerator, $profiler, $twig, []);
+
+ $response = $controller->toolbarStylesheetAction();
+ $this->assertSame(200, $response->getStatusCode());
+ $this->assertSame('text/css', $response->headers->get('Content-Type'));
+ $this->assertSame('max-age=600, private', $response->headers->get('Cache-Control'));
+ }
+
public static function getEmptyTokenCases()
{
return [
@@ -225,7 +252,7 @@ public function testSearchBarActionDefaultPage()
$this->assertSame(200, $client->getResponse()->getStatusCode());
foreach (['ip', 'status_code', 'url', 'token', 'start', 'end'] as $searchCriteria) {
- $this->assertSame('', $crawler->filter(sprintf('form input[name="%s"]', $searchCriteria))->text());
+ $this->assertSame('', $crawler->filter(\sprintf('form input[name="%s"]', $searchCriteria))->text());
}
}
@@ -334,7 +361,7 @@ public function testSearchActionWithoutToken()
$client->request('GET', '/_profiler/search?ip=&method=GET&status_code=&url=&token=&start=&end=&limit=10');
$this->assertStringContainsString('results found', $client->getResponse()->getContent());
- $this->assertStringContainsString(sprintf('%s ', $token, $token), $client->getResponse()->getContent());
+ $this->assertStringContainsString(\sprintf('%s ', $token, $token), $client->getResponse()->getContent());
}
public function testPhpinfoActionWithProfilerDisabled()
diff --git a/Tests/DependencyInjection/WebProfilerExtensionTest.php b/Tests/DependencyInjection/WebProfilerExtensionTest.php
index dd367b4c..490bc91e 100644
--- a/Tests/DependencyInjection/WebProfilerExtensionTest.php
+++ b/Tests/DependencyInjection/WebProfilerExtensionTest.php
@@ -57,8 +57,6 @@ public static function assertSaneContainer(Container $container)
protected function setUp(): void
{
- parent::setUp();
-
$this->kernel = $this->createMock(KernelInterface::class);
$this->container = new ContainerBuilder();
@@ -87,8 +85,6 @@ protected function setUp(): void
protected function tearDown(): void
{
- parent::tearDown();
-
$this->container = null;
}
diff --git a/Tests/Profiler/CodeExtensionTest.php b/Tests/Profiler/CodeExtensionTest.php
index 8a2c88a3..7cdedfe8 100644
--- a/Tests/Profiler/CodeExtensionTest.php
+++ b/Tests/Profiler/CodeExtensionTest.php
@@ -21,7 +21,7 @@ class CodeExtensionTest extends TestCase
{
public function testFormatFile()
{
- $expected = sprintf('%s at line 25 ', substr(__FILE__, 5), __FILE__);
+ $expected = \sprintf('%s at line 25 ', substr(__FILE__, 5), __FILE__);
$this->assertEquals($expected, $this->getExtension()->formatFile(__FILE__, 25));
}
diff --git a/Tests/Profiler/TemplateManagerTest.php b/Tests/Profiler/TemplateManagerTest.php
index b837fc66..e5bf05b3 100644
--- a/Tests/Profiler/TemplateManagerTest.php
+++ b/Tests/Profiler/TemplateManagerTest.php
@@ -30,8 +30,6 @@ class TemplateManagerTest extends TestCase
protected function setUp(): void
{
- parent::setUp();
-
$this->profiler = $this->createMock(Profiler::class);
$twigEnvironment = $this->mockTwigEnvironment();
$templates = [
diff --git a/Tests/Resources/IconTest.php b/Tests/Resources/IconTest.php
index 8b9cf721..4cddbe0f 100644
--- a/Tests/Resources/IconTest.php
+++ b/Tests/Resources/IconTest.php
@@ -23,13 +23,13 @@ public function testIconFileContents($iconFilePath)
$iconFilePath = realpath($iconFilePath);
$svgFileContents = file_get_contents($iconFilePath);
- $this->assertStringContainsString('xmlns="http://www.w3.org/2000/svg"', $svgFileContents, sprintf('The SVG metadata of the "%s" icon must use "http://www.w3.org/2000/svg" as its "xmlns" value.', $iconFilePath));
+ $this->assertStringContainsString('xmlns="http://www.w3.org/2000/svg"', $svgFileContents, \sprintf('The SVG metadata of the "%s" icon must use "http://www.w3.org/2000/svg" as its "xmlns" value.', $iconFilePath));
- $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), sprintf('The SVG file of the "%s" icon must include a "width" attribute.', $iconFilePath));
+ $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), \sprintf('The SVG file of the "%s" icon must include a "width" attribute.', $iconFilePath));
- $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), sprintf('The SVG file of the "%s" icon must include a "height" attribute.', $iconFilePath));
+ $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), \sprintf('The SVG file of the "%s" icon must include a "height" attribute.', $iconFilePath));
- $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), sprintf('The SVG file of the "%s" icon must include a "viewBox" attribute.', $iconFilePath));
+ $this->assertMatchesRegularExpression('~.* ~s', file_get_contents($iconFilePath), \sprintf('The SVG file of the "%s" icon must include a "viewBox" attribute.', $iconFilePath));
}
public static function provideIconFilePaths(): array
diff --git a/composer.json b/composer.json
index a6a1cf2d..ce94b4b6 100644
--- a/composer.json
+++ b/composer.json
@@ -22,7 +22,7 @@
"symfony/http-kernel": "^6.4|^7.0",
"symfony/routing": "^6.4|^7.0",
"symfony/twig-bundle": "^6.4|^7.0",
- "twig/twig": "^3.10"
+ "twig/twig": "^3.12"
},
"require-dev": {
"symfony/browser-kit": "^6.4|^7.0",
@@ -33,7 +33,8 @@
"conflict": {
"symfony/form": "<6.4",
"symfony/mailer": "<6.4",
- "symfony/messenger": "<6.4"
+ "symfony/messenger": "<6.4",
+ "symfony/serializer": "<7.2"
},
"autoload": {
"psr-4": { "Symfony\\Bundle\\WebProfilerBundle\\": "" },
pFad - Phonifier reborn
Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.
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:
Alternative Proxy
pFad Proxy
pFad v3 Proxy
pFad v4 Proxy