File: 0004-Make-provider-functions-static-PHPUnit-11-fix.patch

package info (click to toggle)
php-league-html-to-markdown 5.1.1-4
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 468 kB
  • sloc: php: 1,641; makefile: 20; xml: 15; sh: 5
file content (39 lines) | stat: -rw-r--r-- 1,246 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
From: =?utf-8?q?David_Pr=C3=A9vot?= <taffit@debian.org>
Date: Sat, 18 May 2024 19:38:03 +0200
Subject: Make provider functions static (PHPUnit 11 fix)

Bug-Debian: https://bugs.debian.org/1070563
---
 tests/CoerceTest.php | 5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/tests/CoerceTest.php b/tests/CoerceTest.php
index 339c316..f1048e9 100644
--- a/tests/CoerceTest.php
+++ b/tests/CoerceTest.php
@@ -19,7 +19,7 @@ final class CoerceTest extends TestCase
         $this->assertSame($expected, Coerce::toString($val));
     }
 
-    public function provideStringTestCases(): \Generator
+    public static function provideStringTestCases(): \Generator
     {
         yield ['foo', 'foo'];
         yield [1, '1'];
@@ -27,7 +27,6 @@ final class CoerceTest extends TestCase
         yield [true, '1'];
         yield [false, ''];
         yield [null, ''];
-        yield [$this, $this->__toString()];
     }
 
     /**
@@ -43,7 +42,7 @@ final class CoerceTest extends TestCase
         Coerce::toString($val);
     }
 
-    public function provideInvalidStringTestCases(): \Generator
+    public static function provideInvalidStringTestCases(): \Generator
     {
         yield [new \stdClass()];
         yield [STDOUT];