1
1
<?php
2
2
3
- use cli \ Arguments ;
3
+ use PHPUnit \ Framework \ Attributes \ DataProvider ;
4
4
use WP_CLI \Tests \TestCase ;
5
5
6
6
/**
@@ -255,6 +255,7 @@ private function _testParse($cliParams, $expectedValues)
255
255
*
256
256
* @dataProvider settingsWithValidOptions
257
257
*/
258
+ #[DataProvider( 'settingsWithValidOptions ' )] // phpcs:ignore PHPCompatibility.Attributes.NewAttributes.PHPUnitAttributeFound
258
259
public function testParseWithValidOptions ($ cliParams , $ expectedValues )
259
260
{
260
261
$ this ->_testParse ($ cliParams , $ expectedValues );
@@ -265,6 +266,7 @@ public function testParseWithValidOptions($cliParams, $expectedValues)
265
266
* @param array $expectedValues expected values after parsing
266
267
* @dataProvider settingsWithMissingOptions
267
268
*/
269
+ #[DataProvider( 'settingsWithMissingOptions ' )] // phpcs:ignore PHPCompatibility.Attributes.NewAttributes.PHPUnitAttributeFound
268
270
public function testParseWithMissingOptions ($ cliParams , $ expectedValues )
269
271
{
270
272
$ this ->expectException (\Exception::class);
@@ -277,6 +279,7 @@ public function testParseWithMissingOptions($cliParams, $expectedValues)
277
279
* @param array $expectedValues expected values after parsing
278
280
* @dataProvider settingsWithMissingOptionsWithDefault
279
281
*/
282
+ #[DataProvider( 'settingsWithMissingOptionsWithDefault ' )] // phpcs:ignore PHPCompatibility.Attributes.NewAttributes.PHPUnitAttributeFound
280
283
public function testParseWithMissingOptionsWithDefault ($ cliParams , $ expectedValues )
281
284
{
282
285
$ this ->_testParse ($ cliParams , $ expectedValues );
@@ -287,6 +290,7 @@ public function testParseWithMissingOptionsWithDefault($cliParams, $expectedValu
287
290
* @param array $expectedValues expected values after parsing
288
291
* @dataProvider settingsWithNoOptionsWithDefault
289
292
*/
293
+ #[DataProvider( 'settingsWithNoOptionsWithDefault ' )] // phpcs:ignore PHPCompatibility.Attributes.NewAttributes.PHPUnitAttributeFound
290
294
public function testParseWithNoOptionsWithDefault ($ cliParams , $ expectedValues ) {
291
295
$ this ->_testParse ($ cliParams , $ expectedValues );
292
296
}
0 commit comments