phpstan-phpunit icon indicating copy to clipboard operation
phpstan-phpunit copied to clipboard

Warn when data provider provides more args than the method accepts

Open ondrejmirtes opened this issue 1 month ago • 1 comments

Allegedly PHPUnit 12 warns about this.

At the same time, PHPUnit 12.4 adds validateArgumentCount parameter to DataProvider attribute that opts out of this error.

/cc @staabm

ondrejmirtes avatar Nov 06 '25 14:11 ondrejmirtes

related PHPUnit issue: https://github.com/sebastianbergmann/phpunit/issues/6277

staabm avatar Nov 28 '25 10:11 staabm