We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 956c3bb commit b480bf1Copy full SHA for b480bf1
1 file changed
src/Codeception/Module/Yii2.php
@@ -460,8 +460,8 @@ public function _after(TestInterface $test): void
460
*/
461
public function _failed(TestInterface $test, $fail): void
462
{
463
- $log = $this->yiiLogger->getAndClearLog();
464
- if ($log !== '') {
+ $log = $this->yiiLogger?->getAndClearLog();
+ if (isset($log) && $log !== '') {
465
$test->getMetadata()->addReport('yii-log', $log);
466
}
467
0 commit comments