You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In throwing an exception within my Behat Step definition, I correctly fail a given behat test. However, before the command returns, I get the following:
Recoverable fatal error: Argument 1 passed to emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter::onAfterSuiteTested() must be an instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteTested, instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteAborted given in emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter->onAfterSuiteTested() (line 474 of [excluded]/vendor/emuse/behat-html-formatter/src/Formatter/BehatHTMLFormatter.php).
I was able to resolve this issue (and a subsequent one) by changing
public function onAfterSuiteTested(AfterSuiteTested $event)
and public function onAfterExercise(AfterExerciseCompleted $event)
to
public function onAfterSuiteTested(\Behat\Testwork\EventDispatcher\Event\SuiteTested $event)
and public function onAfterExercise(\Behat\Testwork\EventDispatcher\Event\ExerciseCompleted $event)
Is there a reason you're using the specific classes rather than the interfaces here?
The text was updated successfully, but these errors were encountered:
TypeError: Argument 1 passed to emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter::onAfterSuiteTested() must be an instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteTested, instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteAborted given in emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter->onAfterSuiteTested() (line 416 of vendor/emuse/behat-html-formatter/src/Formatter/BehatHTMLFormatter.php).
In throwing an exception within my Behat Step definition, I correctly fail a given behat test. However, before the command returns, I get the following:
Recoverable fatal error: Argument 1 passed to emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter::onAfterSuiteTested() must be an instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteTested, instance of Behat\Testwork\EventDispatcher\Event\AfterSuiteAborted given in emuse\BehatHTMLFormatter\Formatter\BehatHTMLFormatter->onAfterSuiteTested() (line 474 of [excluded]/vendor/emuse/behat-html-formatter/src/Formatter/BehatHTMLFormatter.php).
I was able to resolve this issue (and a subsequent one) by changing
public function onAfterSuiteTested(AfterSuiteTested $event)
and
public function onAfterExercise(AfterExerciseCompleted $event)
to
public function onAfterSuiteTested(\Behat\Testwork\EventDispatcher\Event\SuiteTested $event)
and
public function onAfterExercise(\Behat\Testwork\EventDispatcher\Event\ExerciseCompleted $event)
Is there a reason you're using the specific classes rather than the interfaces here?
The text was updated successfully, but these errors were encountered: