Skip to content

Commit fe45278

Browse files
committed
Merge branch '5.4' into 6.2
* 5.4: Fix some Composer keywords [FrameworkBundle] Rename limiter’s `strategy` to `policy` in XSD [VarDumper] Fixed dumping of CutStub Fix test Change limit argument from string to integer. [Messenger] Fix `evaluate()` calls in `WorkerTest` [Mailer] STDOUT blocks infinitely under Windows when STDERR is filled
2 parents 4bf2bab + cc05652 commit fe45278

File tree

1 file changed

+8
-6
lines changed

1 file changed

+8
-6
lines changed

Tests/Store/DoctrineDbalStoreTest.php

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -153,14 +153,15 @@ public function testTableCreationInTransactionNotSupported()
153153
$conn->expects($this->atLeast(2))
154154
->method('executeStatement')
155155
->willReturnCallback(function ($sql) use (&$series) {
156-
[$constraint, $return] = array_shift($series);
157-
$constraint->evaluate($sql);
156+
if ([$constraint, $return] = array_shift($series)) {
157+
$constraint->evaluate($sql);
158+
}
158159

159160
if ($return instanceof \Exception) {
160161
throw $return;
161162
}
162163

163-
return $return;
164+
return $return ?? 1;
164165
})
165166
;
166167

@@ -194,14 +195,15 @@ public function testCreatesTableOutsideTransaction()
194195
$conn->expects($this->atLeast(3))
195196
->method('executeStatement')
196197
->willReturnCallback(function ($sql) use (&$series) {
197-
[$constraint, $return] = array_shift($series);
198-
$constraint->evaluate($sql);
198+
if ([$constraint, $return] = array_shift($series)) {
199+
$constraint->evaluate($sql);
200+
}
199201

200202
if ($return instanceof \Exception) {
201203
throw $return;
202204
}
203205

204-
return $return;
206+
return $return ?? 1;
205207
})
206208
;
207209

0 commit comments

Comments
 (0)