Add PHPUnit attributes alongside annotations to silence doc-comment metadata deprecations on PHPUnit 11

This commit is contained in:
Fabien Potencier
2026-06-03 18:26:39 +02:00
parent 8b35934e68
commit 8a4b77920a
32 changed files with 152 additions and 5 deletions
@@ -11,6 +11,7 @@
namespace Twig\Tests\TokenParser;
use PHPUnit\Framework\Attributes\DataProvider;
use PHPUnit\Framework\TestCase;
use Twig\Environment;
use Twig\Loader\ArrayLoader;
@@ -20,6 +21,7 @@ use Twig\Source;
class TypesTokenParserTest extends TestCase
{
/** @dataProvider getMappingTests */
#[DataProvider('getMappingTests')]
public function testMappingParsing(string $template, array $expected): void
{
$env = new Environment(new ArrayLoader(), ['cache' => false, 'autoescape' => false]);