/
githubmirror
/
symfony
Обзор
Документация
Войти
/
githubmirror
/
symfony
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
8.2
src/Symfony/Component/Routing/Tests/Loader/ContainerLoaderTest.php
35 строк
921 B
Christian Flothmann
replace PHPUnit annotations with attributes
04 авг 2025, 10:05
04 авг 2025, 10:05
982f89c
Код
Авторство
О чём код?
<?php /* * This file is part of the Symfony package. * * (c) Fabien Potencier <fabien@symfony.com> * * For the full copyright and license information, please view the LICENSE * file that was distributed with this source code. */ namespace Symfony\Component\Routing\Tests\Loader; use PHPUnit\Framework\Attributes\DataProvider; use PHPUnit\Framework\TestCase; use Symfony\Component\DependencyInjection\Container; use Symfony\Component\Routing\Loader\ContainerLoader; class ContainerLoaderTest extends TestCase { #[DataProvider('supportsProvider')] public function testSupports(bool $expected, ?string $type = null) { $this->assertSame($expected, (new ContainerLoader(new Container()))->supports('foo', $type)); } public static function supportsProvider() { return [ [true, 'service'], [false, 'bar'], [false, null], ]; } }