Skip to content

Commit e131e35

Browse files
committed
Fix
1 parent 0f5b4bf commit e131e35

File tree

1 file changed

+13
-1
lines changed

1 file changed

+13
-1
lines changed

tests/PHPStan/Rules/Arrays/ArrayUnpackingRuleTest.php

Lines changed: 13 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,24 @@ public function testRuleDoNotCheckUnions(): void
8282
]);
8383
}
8484

85-
public function testRuleOnPHP81(): void
85+
public function dataRuleOnPHP81(): array
86+
{
87+
return [
88+
[true],
89+
[false],
90+
];
91+
}
92+
93+
/**
94+
* @dataProvider dataRuleOnPHP81
95+
*/
96+
public function testRuleOnPHP81(bool $checkUnions): void
8697
{
8798
if (PHP_VERSION_ID < 80100) {
8899
$this->markTestSkipped('Test requires PHP 8.1+');
89100
}
90101

102+
$this->checkUnions = $checkUnions;
91103
$this->analyse([__DIR__ . '/data/array-unpacking.php'], []);
92104
}
93105

0 commit comments

Comments
 (0)