File tree Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Expand file tree Collapse file tree 2 files changed +8
-4
lines changed Original file line number Diff line number Diff line change 4
4
<phpunit xmlns : xsi =" http://www.w3.org/2001/XMLSchema-instance"
5
5
xsi : noNamespaceSchemaLocation =" https://schema.phpunit.de/9.3/phpunit.xsd"
6
6
bootstrap =" vendor/autoload.php"
7
+ cacheResult =" false"
7
8
colors =" true"
8
- cacheResult = " false " >
9
+ convertDeprecationsToExceptions = " true " >
9
10
<testsuites >
10
11
<testsuite name =" Promise Test Suite" >
11
12
<directory >./tests/</directory >
19
20
<file >./src/functions_include.php</file >
20
21
</exclude >
21
22
</coverage >
23
+ <php >
24
+ <ini name =" error_reporting" value =" -1" />
25
+ </php >
22
26
</phpunit >
Original file line number Diff line number Diff line change @@ -29,15 +29,15 @@ public function getPromiseTestAdapter(callable $canceller = null)
29
29
'resolve ' => function () {
30
30
throw new LogicException ('You cannot call resolve() for React\Promise\RejectedPromise ' );
31
31
},
32
- 'reject ' => function ($ reason = null ) use (&$ promise ) {
32
+ 'reject ' => function (\ Throwable $ reason ) use (&$ promise ) {
33
33
if (!$ promise ) {
34
34
$ promise = new RejectedPromise ($ reason );
35
35
}
36
36
},
37
- 'settle ' => function ($ reason = "" ) use (&$ promise ) {
37
+ 'settle ' => function ($ reason = '' ) use (&$ promise ) {
38
38
if (!$ promise ) {
39
39
if (!$ reason instanceof Exception) {
40
- $ reason = new Exception ($ reason );
40
+ $ reason = new Exception (( string ) $ reason );
41
41
}
42
42
43
43
$ promise = new RejectedPromise ($ reason );
You can’t perform that action at this time.
0 commit comments