1313
1414use Massive \Bundle \BuildBundle \Console \MassiveOutputFormatter ;
1515use Massive \Bundle \BuildBundle \Tests \BaseTestCase ;
16+ use PHPUnit \Framework \Attributes \DataProvider ;
1617
1718class MassiveOutputFormatterTest extends BaseTestCase
1819{
@@ -23,6 +24,7 @@ class MassiveOutputFormatterTest extends BaseTestCase
2324 *
2425 * @dataProvider getDecorationDataProvider
2526 */
27+ #[DataProvider('getDecorationDataProvider ' )]
2628 public function testThatOutputWillBeDecorated ($ message , $ indent , $ expected )
2729 {
2830 $ formatter = new MassiveOutputFormatter (true );
@@ -33,11 +35,9 @@ public function testThatOutputWillBeDecorated($message, $indent, $expected)
3335
3436 public static function getDecorationDataProvider ()
3537 {
36- return [
37- ['Some string ' , 0 , 'Some string ' ],
38- ['Some string ' , 1 , ' Some string ' ],
39- ['Some string ' , 2 , ' Some string ' ],
40- ];
38+ yield ['Some string ' , 0 , 'Some string ' ];
39+ yield ['Some string ' , 1 , ' Some string ' ];
40+ yield ['Some string ' , 2 , ' Some string ' ];
4141 }
4242
4343 /**
@@ -46,6 +46,7 @@ public static function getDecorationDataProvider()
4646 *
4747 * @dataProvider getNonDecorationDataProvider
4848 */
49+ #[DataProvider('getNonDecorationDataProvider ' )]
4950 public function testThatOutputWillNotBeDecorated ($ message , $ indent )
5051 {
5152 $ formatter = new MassiveOutputFormatter (false );
0 commit comments