mirror of
https://github.com/danog/endtoend-test-psl.git
synced 2024-11-26 20:34:59 +01:00
fix coding standards
This commit is contained in:
parent
57a8741d71
commit
7eb29b80dd
@ -10,8 +10,8 @@ use Psl\Type;
|
||||
use Psl\Type\Exception\AssertException;
|
||||
use Psl\Type\Exception\CoercionException;
|
||||
|
||||
use function is_iterable;
|
||||
use function is_array;
|
||||
use function is_iterable;
|
||||
|
||||
/**
|
||||
* @template Tk of array-key
|
||||
|
@ -85,7 +85,7 @@ abstract class TypeTest extends TestCase
|
||||
*/
|
||||
public function testMatches($value): void
|
||||
{
|
||||
static::assertTrue($this->getType()->matches($value));
|
||||
static::assertTrue($this->getType()->matches($value));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -23,6 +23,11 @@ final class VecTypeTest extends TypeTest
|
||||
|
||||
public function getValidCoercions(): iterable
|
||||
{
|
||||
yield [
|
||||
[],
|
||||
[]
|
||||
];
|
||||
|
||||
yield [
|
||||
[1, 2, 3, 4, 5, 6, 7, 8, 9, 10],
|
||||
[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
|
||||
@ -62,6 +67,11 @@ final class VecTypeTest extends TypeTest
|
||||
Dict\map(Vec\range(1, 10), static fn(int $value): string => Str\format('00%d', $value)),
|
||||
[1, 2, 3, 4, 5, 6, 7, 8, 9, 10]
|
||||
];
|
||||
|
||||
yield [
|
||||
['a' => 1, 'b' => 2, 'c' => 3, 'd' => 4, 'e' => 5],
|
||||
[1, 2, 3, 4, 5]
|
||||
];
|
||||
}
|
||||
|
||||
public function getInvalidCoercions(): iterable
|
||||
|
Loading…
Reference in New Issue
Block a user