Skip to content

Commit a6c6232

Browse files
authored
Merge pull request #292 from simPod/patch-something
refactor: just rerun patch targets
2 parents baff79f + 4437c60 commit a6c6232

File tree

4 files changed

+73
-76
lines changed

4 files changed

+73
-76
lines changed

tests/php72-compatibility.patch

Lines changed: 29 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
diff --git a/tests/expected_report.txt b/tests/expected_report.txt
2-
index 5110131..53dada5 100644
2+
index 151bce4..0afca8c 100644
33
--- a/tests/expected_report.txt
44
+++ b/tests/expected_report.txt
55
@@ -14,26 +14,23 @@ tests/input/constants-var.php 7 0
@@ -63,7 +63,7 @@ diff --git a/tests/fixed/ControlStructures.php b/tests/fixed/ControlStructures.p
6363
index f8f7f65..a653086 100644
6464
--- a/tests/fixed/ControlStructures.php
6565
+++ b/tests/fixed/ControlStructures.php
66-
@@ -104,7 +104,7 @@ public function spaceBelowBlocks(): void
66+
@@ -104,7 +104,7 @@ class ControlStructures
6767

6868
try {
6969
echo 4;
@@ -76,7 +76,7 @@ diff --git a/tests/fixed/EarlyReturn.php b/tests/fixed/EarlyReturn.php
7676
index fc734db..caf1dbb 100644
7777
--- a/tests/fixed/EarlyReturn.php
7878
+++ b/tests/fixed/EarlyReturn.php
79-
@@ -11,7 +11,7 @@ public function bar(): bool
79+
@@ -11,7 +11,7 @@ class EarlyReturn
8080
return $bar === 'bar';
8181
}
8282

@@ -117,7 +117,7 @@ diff --git a/tests/fixed/NamingCamelCase.php b/tests/fixed/NamingCamelCase.php
117117
index 5493471..57d9f2b 100644
118118
--- a/tests/fixed/NamingCamelCase.php
119119
+++ b/tests/fixed/NamingCamelCase.php
120-
@@ -6,11 +6,14 @@
120+
@@ -6,11 +6,14 @@ namespace Example;
121121

122122
class NamingCamelCase
123123
{
@@ -155,7 +155,7 @@ diff --git a/tests/fixed/TrailingCommaOnFunctions.php b/tests/fixed/TrailingComm
155155
index 4248238..f3ffa91 100644
156156
--- a/tests/fixed/TrailingCommaOnFunctions.php
157157
+++ b/tests/fixed/TrailingCommaOnFunctions.php
158-
@@ -15,7 +15,7 @@ public function a(int $arg): void
158+
@@ -15,7 +15,7 @@ class TrailingCommaOnFunctions
159159
}
160160

161161
public function b(
@@ -164,7 +164,7 @@ index 4248238..f3ffa91 100644
164164
): void {
165165
}
166166

167-
@@ -28,7 +28,7 @@ public function uses(): void
167+
@@ -28,7 +28,7 @@ class TrailingCommaOnFunctions
168168
};
169169

170170
$multiLine = static function (int $arg) use (
@@ -173,7 +173,7 @@ index 4248238..f3ffa91 100644
173173
): void {
174174
var_dump($var);
175175
};
176-
@@ -37,9 +37,8 @@ public function uses(): void
176+
@@ -37,9 +37,8 @@ class TrailingCommaOnFunctions
177177

178178
$class = new TrailingCommaOnFunctions();
179179

@@ -188,7 +188,7 @@ diff --git a/tests/fixed/UselessConditions.php b/tests/fixed/UselessConditions.p
188188
index 71e0cfb..2151b17 100644
189189
--- a/tests/fixed/UselessConditions.php
190190
+++ b/tests/fixed/UselessConditions.php
191-
@@ -95,7 +95,7 @@ public function necessaryIfConditionWithMethodCall(): bool
191+
@@ -95,7 +95,7 @@ class UselessConditions
192192
return false;
193193
}
194194

@@ -201,7 +201,7 @@ diff --git a/tests/fixed/arrow-functions-format.php b/tests/fixed/arrow-function
201201
index 4da39b8..a45074f 100644
202202
--- a/tests/fixed/arrow-functions-format.php
203203
+++ b/tests/fixed/arrow-functions-format.php
204-
@@ -18,10 +18,10 @@
204+
@@ -18,10 +18,10 @@ $returningObject = static fn () => new stdClass();
205205

206206
$multiLineArrowFunctions = Collection::from([1, 2])
207207
->map(
@@ -215,10 +215,10 @@ index 4da39b8..a45074f 100644
215215

216216
$thisIsNotAnArrowFunction = [$this->fn => 'value'];
217217
diff --git a/tests/fixed/example-class.php b/tests/fixed/example-class.php
218-
index 7d27825..998e51d 100644
218+
index 4988dab..2df56a0 100644
219219
--- a/tests/fixed/example-class.php
220220
+++ b/tests/fixed/example-class.php
221-
@@ -29,19 +29,32 @@ class Example extends ParentClass implements IteratorAggregate
221+
@@ -29,10 +29,23 @@ class Example extends ParentClass implements IteratorAggregate
222222
{
223223
private const VERSION = PHP_VERSION - (PHP_MINOR_VERSION * 100) - PHP_PATCH_VERSION;
224224

@@ -242,10 +242,9 @@ index 7d27825..998e51d 100644
242242
+ $this->bar = $bar;
243243
+ $this->baz = $baz;
244244
$this->baxBax = $baxBax;
245-
246-
parent::__construct();
247-
}
248245

246+
parent::__construct();
247+
@@ -41,7 +54,7 @@ class Example extends ParentClass implements IteratorAggregate
249248
/**
250249
* Description
251250
*/
@@ -258,7 +257,7 @@ diff --git a/tests/fixed/namespaces-spacing.php b/tests/fixed/namespaces-spacing
258257
index 36cbae2..d42bbfe 100644
259258
--- a/tests/fixed/namespaces-spacing.php
260259
+++ b/tests/fixed/namespaces-spacing.php
261-
@@ -16,5 +16,5 @@
260+
@@ -16,5 +16,5 @@ use const DATE_RFC3339;
262261
strrev(
263262
(new DateTimeImmutable('@' . time(), new DateTimeZone('UTC')))
264263
->sub(new DateInterval('P1D'))
@@ -269,7 +268,7 @@ diff --git a/tests/fixed/new_with_parentheses.php b/tests/fixed/new_with_parenth
269268
index 47a06ec..6e81bbe 100644
270269
--- a/tests/fixed/new_with_parentheses.php
271270
+++ b/tests/fixed/new_with_parentheses.php
272-
@@ -24,5 +24,5 @@
271+
@@ -24,5 +24,5 @@ $y = [new stdClass()];
273272

274273
$z = new stdClass() ? new stdClass() : new stdClass();
275274

@@ -303,7 +302,7 @@ diff --git a/tests/fixed/null_coalesce_operator.php b/tests/fixed/null_coalesce_
303302
index 51c361c..8846dd1 100644
304303
--- a/tests/fixed/null_coalesce_operator.php
305304
+++ b/tests/fixed/null_coalesce_operator.php
306-
@@ -4,7 +4,7 @@
305+
@@ -4,7 +4,7 @@ declare(strict_types=1);
307306

308307
$foo = $_GET['foo'] ?? 'foo';
309308

@@ -374,7 +373,7 @@ diff --git a/tests/fixed/return_type_on_methods.php b/tests/fixed/return_type_on
374373
index 0c897ae..8e2c6f7 100644
375374
--- a/tests/fixed/return_type_on_methods.php
376375
+++ b/tests/fixed/return_type_on_methods.php
377-
@@ -31,7 +31,7 @@ public function f(
376+
@@ -31,7 +31,7 @@ class Test
378377
int $c,
379378
int $d,
380379
int $e,
@@ -383,7 +382,7 @@ index 0c897ae..8e2c6f7 100644
383382
): void {
384383
}
385384

386-
@@ -40,7 +40,7 @@ public function g(
385+
@@ -40,7 +40,7 @@ class Test
387386
int $c,
388387
int $d,
389388
int $e,
@@ -392,7 +391,7 @@ index 0c897ae..8e2c6f7 100644
392391
): void {
393392
}
394393

395-
@@ -49,7 +49,7 @@ public function h(
394+
@@ -49,7 +49,7 @@ class Test
396395
int $c,
397396
int $d,
398397
int $e,
@@ -401,7 +400,7 @@ index 0c897ae..8e2c6f7 100644
401400
): void {
402401
}
403402

404-
@@ -58,7 +58,7 @@ public function i(
403+
@@ -58,7 +58,7 @@ class Test
405404
int $c,
406405
int $d,
407406
int $e,
@@ -410,7 +409,7 @@ index 0c897ae..8e2c6f7 100644
410409
): void {
411410
}
412411

413-
@@ -67,7 +67,7 @@ public function j(
412+
@@ -67,7 +67,7 @@ class Test
414413
int $c,
415414
int $d,
416415
int $e,
@@ -423,7 +422,7 @@ diff --git a/tests/fixed/type-hints.php b/tests/fixed/type-hints.php
423422
index 5e26ed8..10e6f34 100644
424423
--- a/tests/fixed/type-hints.php
425424
+++ b/tests/fixed/type-hints.php
426-
@@ -10,7 +10,7 @@
425+
@@ -10,7 +10,7 @@ use Traversable;
427426
class TraversableTypeHints
428427
{
429428
/** @var Traversable */
@@ -432,7 +431,7 @@ index 5e26ed8..10e6f34 100644
432431

433432
/**
434433
* @param Iterator $iterator
435-
@@ -25,5 +25,6 @@ public function get(Iterator $iterator): Traversable
434+
@@ -25,5 +25,6 @@ class TraversableTypeHints
436435

437436
class UnionTypeHints
438437
{
@@ -444,7 +443,7 @@ diff --git a/tests/input/ControlStructures.php b/tests/input/ControlStructures.p
444443
index 73944e3..a0e0b2e 100644
445444
--- a/tests/input/ControlStructures.php
446445
+++ b/tests/input/ControlStructures.php
447-
@@ -93,7 +93,7 @@ public function spaceBelowBlocks(): void
446+
@@ -93,7 +93,7 @@ class ControlStructures
448447
}
449448
try {
450449
echo 4;
@@ -499,7 +498,7 @@ diff --git a/tests/input/TrailingCommaOnFunctions.php b/tests/input/TrailingComm
499498
index fc5480e..f3ffa91 100644
500499
--- a/tests/input/TrailingCommaOnFunctions.php
501500
+++ b/tests/input/TrailingCommaOnFunctions.php
502-
@@ -10,7 +10,7 @@
501+
@@ -10,7 +10,7 @@ use function var_dump;
503502

504503
class TrailingCommaOnFunctions
505504
{
@@ -508,7 +507,7 @@ index fc5480e..f3ffa91 100644
508507
{
509508
}
510509

511-
@@ -23,7 +23,7 @@ public function uses(): void
510+
@@ -23,7 +23,7 @@ class TrailingCommaOnFunctions
512511
{
513512
$var = null;
514513

@@ -517,7 +516,7 @@ index fc5480e..f3ffa91 100644
517516
var_dump($var);
518517
};
519518

520-
@@ -37,8 +37,7 @@ public function uses(): void
519+
@@ -37,8 +37,7 @@ class TrailingCommaOnFunctions
521520

522521
$class = new TrailingCommaOnFunctions();
523522

@@ -531,7 +530,7 @@ diff --git a/tests/input/arrow-functions-format.php b/tests/input/arrow-function
531530
index d3903ff..8a358e8 100644
532531
--- a/tests/input/arrow-functions-format.php
533532
+++ b/tests/input/arrow-functions-format.php
534-
@@ -18,10 +18,10 @@
533+
@@ -18,10 +18,10 @@ $returningObject = static fn () => new stdClass();
535534

536535
$multiLineArrowFunctions = Collection::from([1, 2])
537536
->map(
@@ -548,7 +547,7 @@ diff --git a/tests/input/namespaces-spacing.php b/tests/input/namespaces-spacing
548547
index e7be018..e1ab639 100644
549548
--- a/tests/input/namespaces-spacing.php
550549
+++ b/tests/input/namespaces-spacing.php
551-
@@ -11,5 +11,5 @@
550+
@@ -11,5 +11,5 @@ use const DATE_RFC3339;
552551
strrev(
553552
(new DateTimeImmutable('@' . time(), new DateTimeZone('UTC')))
554553
->sub(new DateInterval('P1D'))

0 commit comments

Comments
 (0)