PHPUnit - Don't fail when the dataProvider returns an empty array
问题 I have a PHPUnit test which uses a @dataProvider . The dataprovider checks the filesystem for certain files. However I'm using this test in different environments what means it can happen that the files do not exist. This means that the dataProvider does not find anything and that the test is not executed. And this causes the test run to end in a failure. Question: is the a way to configure PHPUnit to ignore tests which have providers that produce nothing? 回答1: While I do not know of any