Skip to content

Commit 2b09e0f

Browse files
committed
Update PHPDoc for data providers
1 parent 6a05b3b commit 2b09e0f

File tree

5 files changed

+36
-5
lines changed

5 files changed

+36
-5
lines changed

phpstan.tests.neon

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,3 @@ parameters:
33

44
paths:
55
- tests
6-
7-
ignoreErrors:
8-
# Disable errors about missing value types in PHPUnit data providers
9-
10-
- '#Method .+Test::\w+DataProvider\(\) return type has no value type specified in iterable type iterable.#'

tests/lib/Parameters/ParameterType/ChannelTypeTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -61,6 +61,9 @@ public function testInvalidOptions(array $options): void
6161
$this->getParameterDefinition($options);
6262
}
6363

64+
/**
65+
* @return iterable<mixed>
66+
*/
6467
public static function validOptionsDataProvider(): iterable
6568
{
6669
return [
@@ -89,6 +92,9 @@ public static function validOptionsDataProvider(): iterable
8992
];
9093
}
9194

95+
/**
96+
* @return iterable<mixed>
97+
*/
9298
public static function invalidOptionsDataProvider(): iterable
9399
{
94100
return [
@@ -151,6 +157,9 @@ public function testIsValueEmpty(mixed $value, bool $isEmpty): void
151157
self::assertSame($isEmpty, $this->type->isValueEmpty(new ParameterDefinition(), $value));
152158
}
153159

160+
/**
161+
* @return iterable<mixed>
162+
*/
154163
public static function emptyDataProvider(): iterable
155164
{
156165
return [

tests/lib/Parameters/ParameterType/ComponentTypeTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -53,6 +53,9 @@ public function testInvalidOptions(array $options): void
5353
$this->getParameterDefinition($options);
5454
}
5555

56+
/**
57+
* @return iterable<mixed>
58+
*/
5659
public static function validOptionsDataProvider(): iterable
5760
{
5861
return [
@@ -75,6 +78,9 @@ public static function validOptionsDataProvider(): iterable
7578
];
7679
}
7780

81+
/**
82+
* @return iterable<mixed>
83+
*/
7884
public static function invalidOptionsDataProvider(): iterable
7985
{
8086
return [
@@ -92,6 +98,9 @@ public function testIsValueEmpty(mixed $value, bool $isEmpty): void
9298
self::assertSame($isEmpty, $this->type->isValueEmpty(new ParameterDefinition(), $value));
9399
}
94100

101+
/**
102+
* @return iterable<mixed>
103+
*/
95104
public static function emptyDataProvider(): iterable
96105
{
97106
return [

tests/lib/Parameters/ParameterType/ProductTypeTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ public function testInvalidOptions(array $options): void
6868
$this->getParameterDefinition($options);
6969
}
7070

71+
/**
72+
* @return iterable<mixed>
73+
*/
7174
public static function validOptionsDataProvider(): iterable
7275
{
7376
return [
@@ -78,6 +81,9 @@ public static function validOptionsDataProvider(): iterable
7881
];
7982
}
8083

84+
/**
85+
* @return iterable<mixed>
86+
*/
8187
public static function invalidOptionsDataProvider(): iterable
8288
{
8389
return [
@@ -135,6 +141,9 @@ public function testIsValueEmpty(mixed $value, bool $isEmpty): void
135141
self::assertSame($isEmpty, $this->type->isValueEmpty(new ParameterDefinition(), $value));
136142
}
137143

144+
/**
145+
* @return iterable<mixed>
146+
*/
138147
public static function emptyDataProvider(): iterable
139148
{
140149
return [

tests/lib/Parameters/ParameterType/TaxonTypeTest.php

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,9 @@ public function testInvalidOptions(array $options): void
6868
$this->getParameterDefinition($options);
6969
}
7070

71+
/**
72+
* @return iterable<mixed>
73+
*/
7174
public static function validOptionsDataProvider(): iterable
7275
{
7376
return [
@@ -78,6 +81,9 @@ public static function validOptionsDataProvider(): iterable
7881
];
7982
}
8083

84+
/**
85+
* @return iterable<mixed>
86+
*/
8187
public static function invalidOptionsDataProvider(): iterable
8288
{
8389
return [
@@ -135,6 +141,9 @@ public function testIsValueEmpty(mixed $value, bool $isEmpty): void
135141
self::assertSame($isEmpty, $this->type->isValueEmpty(new ParameterDefinition(), $value));
136142
}
137143

144+
/**
145+
* @return iterable<mixed>
146+
*/
138147
public static function emptyDataProvider(): iterable
139148
{
140149
return [

0 commit comments

Comments
 (0)