File: 0003-Make-provider-functions-static-PHPUnit-11-Fix.patch

package info (click to toggle)
php-phpdocumentor-reflection-docblock 5.6.3-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,416 kB
  • sloc: php: 9,035; xml: 67; makefile: 54
file content (175 lines) | stat: -rw-r--r-- 7,060 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Sun, 19 May 2024 20:18:45 +0200
Subject: Make provider functions static (PHPUnit 11 Fix)

Bug-Debian: https://bugs.debian.org/1070587
---
 tests/unit/DocBlock/DescriptionFactoryTest.php         | 4 ++--
 tests/unit/DocBlock/StandardTagFactoryTest.php         | 4 ++--
 tests/unit/DocBlock/Tags/AuthorTest.php                | 2 +-
 tests/unit/DocBlock/Tags/ExampleTest.php               | 4 ++--
 tests/unit/DocBlock/Tags/Factory/MethodFactoryTest.php | 2 +-
 tests/unit/DocBlock/Tags/Factory/ParamFactoryTest.php  | 2 +-
 tests/unit/DocBlock/Tags/MethodParameterTest.php       | 2 +-
 tests/unit/DocBlock/Tags/MethodTest.php                | 2 +-
 tests/unit/DocBlockFactoryTest.php                     | 2 +-
 tests/unit/Exception/PcreExceptionTest.php             | 2 +-
 10 files changed, 13 insertions(+), 13 deletions(-)

diff --git a/tests/unit/DocBlock/DescriptionFactoryTest.php b/tests/unit/DocBlock/DescriptionFactoryTest.php
index 7fc90ef..ef00350 100644
--- a/tests/unit/DocBlock/DescriptionFactoryTest.php
+++ b/tests/unit/DocBlock/DescriptionFactoryTest.php
@@ -229,7 +229,7 @@ DESCRIPTION;
      *
      * @return string[][]
      */
-    public function provideSimpleExampleDescriptions(): array
+    public static function provideSimpleExampleDescriptions(): array
     {
         return [
             ['This is text for a description.'],
@@ -242,7 +242,7 @@ DESCRIPTION;
     /**
      * @return string[][]
      */
-    public function provideEscapeSequences(): array
+    public static function provideEscapeSequences(): array
     {
         return [
             ['This is text for a description with a {@}.', 'This is text for a description with a @.'],
diff --git a/tests/unit/DocBlock/StandardTagFactoryTest.php b/tests/unit/DocBlock/StandardTagFactoryTest.php
index 8dfced7..2606cc5 100644
--- a/tests/unit/DocBlock/StandardTagFactoryTest.php
+++ b/tests/unit/DocBlock/StandardTagFactoryTest.php
@@ -481,7 +481,7 @@ class StandardTagFactoryTest extends TestCase
      * @return string[][]
      * @phpstan-return array<string, array<int, string>>
      */
-    public function validTagProvider(): array
+    public static function validTagProvider(): array
     {
         //rendered result is adding a space, because the tags are not rendered properly.
         return [
@@ -544,7 +544,7 @@ class StandardTagFactoryTest extends TestCase
      * @return string[][]
      * @phpstan-return list<array<int, string>>
      */
-    public function invalidTagProvider(): array
+    public static function invalidTagProvider(): array
     {
         return [
             ['@tag[invalid]'],
diff --git a/tests/unit/DocBlock/Tags/AuthorTest.php b/tests/unit/DocBlock/Tags/AuthorTest.php
index a1ce432..e0e2a0b 100644
--- a/tests/unit/DocBlock/Tags/AuthorTest.php
+++ b/tests/unit/DocBlock/Tags/AuthorTest.php
@@ -162,7 +162,7 @@ class AuthorTest extends TestCase
     }
 
     /** @return mixed[][] */
-    public function authorTagProvider(): array
+    public static function authorTagProvider(): array
     {
         return [
             [
diff --git a/tests/unit/DocBlock/Tags/ExampleTest.php b/tests/unit/DocBlock/Tags/ExampleTest.php
index 77bf5a3..4741778 100644
--- a/tests/unit/DocBlock/Tags/ExampleTest.php
+++ b/tests/unit/DocBlock/Tags/ExampleTest.php
@@ -167,7 +167,7 @@ class ExampleTest extends TestCase
     }
 
     /** @return mixed[][] */
-    public function tagContentProvider(): array
+    public static function tagContentProvider(): array
     {
         return [
             [
@@ -244,7 +244,7 @@ class ExampleTest extends TestCase
     }
 
     /** @return mixed[][] */
-    public function invalidExampleProvider(): array
+    public static function invalidExampleProvider(): array
     {
         return [
             'invalid start' => [
diff --git a/tests/unit/DocBlock/Tags/Factory/MethodFactoryTest.php b/tests/unit/DocBlock/Tags/Factory/MethodFactoryTest.php
index 59f148d..3c5c064 100644
--- a/tests/unit/DocBlock/Tags/Factory/MethodFactoryTest.php
+++ b/tests/unit/DocBlock/Tags/Factory/MethodFactoryTest.php
@@ -44,7 +44,7 @@ final class MethodFactoryTest extends TagFactoryTestCase
     }
 
     /** @return array<array<string|Method>> */
-    public function tagProvider(): array
+    public static function tagProvider(): array
     {
         return [
             [
diff --git a/tests/unit/DocBlock/Tags/Factory/ParamFactoryTest.php b/tests/unit/DocBlock/Tags/Factory/ParamFactoryTest.php
index 5c50181..9c7bac2 100644
--- a/tests/unit/DocBlock/Tags/Factory/ParamFactoryTest.php
+++ b/tests/unit/DocBlock/Tags/Factory/ParamFactoryTest.php
@@ -51,7 +51,7 @@ final class ParamFactoryTest extends TagFactoryTestCase
     /**
      * @return array<array-key, string|Param>
      */
-    public function paramInputProvider(): array
+    public static function paramInputProvider(): array
     {
         return [
             [
diff --git a/tests/unit/DocBlock/Tags/MethodParameterTest.php b/tests/unit/DocBlock/Tags/MethodParameterTest.php
index a5fb2f0..751b4a0 100644
--- a/tests/unit/DocBlock/Tags/MethodParameterTest.php
+++ b/tests/unit/DocBlock/Tags/MethodParameterTest.php
@@ -43,7 +43,7 @@ class MethodParameterTest extends TestCase
     }
 
     /** @return array<array{0: Type, 1: mixed, 2: string}> */
-    public function collectionDefaultValuesProvider(): array
+    public static function collectionDefaultValuesProvider(): array
     {
         return [
             [new String_(), '1', '\'1\''],
diff --git a/tests/unit/DocBlock/Tags/MethodTest.php b/tests/unit/DocBlock/Tags/MethodTest.php
index dfc0032..d662158 100644
--- a/tests/unit/DocBlock/Tags/MethodTest.php
+++ b/tests/unit/DocBlock/Tags/MethodTest.php
@@ -409,7 +409,7 @@ class MethodTest extends TestCase
     /**
      * @return string[][]
      */
-    public function collectionReturnTypesProvider(): array
+    public static function collectionReturnTypesProvider(): array
     {
         return [
             ['int[]', Array_::class, Integer::class, Compound::class],
diff --git a/tests/unit/DocBlockFactoryTest.php b/tests/unit/DocBlockFactoryTest.php
index 762a7ac..49a0762 100644
--- a/tests/unit/DocBlockFactoryTest.php
+++ b/tests/unit/DocBlockFactoryTest.php
@@ -202,7 +202,7 @@ DOCBLOCK;
     /**
      * @return string[]
      */
-    public function provideSummaryAndDescriptions(): array
+    public static function provideSummaryAndDescriptions(): array
     {
         return [
             ['This is a DocBlock', 'This is a DocBlock', ''],
diff --git a/tests/unit/Exception/PcreExceptionTest.php b/tests/unit/Exception/PcreExceptionTest.php
index e39db5b..f979976 100644
--- a/tests/unit/Exception/PcreExceptionTest.php
+++ b/tests/unit/Exception/PcreExceptionTest.php
@@ -31,7 +31,7 @@ final class PcreExceptionTest extends TestCase
     /**
      * @return array<int, (string|int)[]>
      */
-    public function errorCodeProvider(): array
+    public static function errorCodeProvider(): array
     {
         return [
             [