tests/phpunit: populate iterable types for phpstan

This commit is contained in:
Dylan K. Taylor
2020-02-06 13:11:56 +00:00
parent 54ccc330d5
commit 532dc0fb6f
6 changed files with 22 additions and 4 deletions

View File

@ -28,7 +28,8 @@ use PHPUnit\Framework\TestCase;
class ConfigTest extends TestCase{
/**
* @return \Generator
* @return \Generator|mixed[][]
* @phpstan-return \Generator<int, array{string, mixed[]}, void, void>
*/
public function fixYamlIndexesProvider() : \Generator{
yield ["x: 1\ny: 2\nz: 3\n", [
@ -60,8 +61,8 @@ class ConfigTest extends TestCase{
/**
* @dataProvider fixYamlIndexesProvider
*
* @param string $test
* @param array $expected
* @param string $test
* @param mixed[] $expected
*/
public function testFixYamlIndexes(string $test, array $expected) : void{
$fixed = Config::fixYAMLIndexes($test);