Open pocky opened 7 years ago
I don't know how to handle the exception, I tried with events and try/catch on setUp
but this is (apparently) not the solution.
this is totally expected, because error_get_last
does not deal with exceptions at all in PHP, but only with errors (warnings, notices, etc...)
Got It! PR incoming!
@pocky Any luck with the PR? If it's not PR-ready, could you at least make a gist of the modification needed to get it to work?
Is this with the exceptions and handlers introduced in behat 3.2? If so I think they should remove the need for this extension altogether if they are used instead of this extension's error observers.
@RemiWoler The problem is the gap between current version (phpspec 2, multi-repository) and my working one (phpspec3, monorep, many PR on extensions). I didn't take time to apply/tests changes on 0.3.0 with Behat 2/3 and phpspec 2 (I tried quickly and it was not good).
Working version for behat 3/phpspec 3 is here https://github.com/pocky/BehatSpec/commit/f72ea6a5b599a4837cee408511289215c49cad78
@RemiWoler Working version for Behat3/phpspec2 is here https://github.com/richardmiller/BehatSpec/pull/11
error_get_last()
return NULL for Behat Exception so exemplify can't work. Could you confirm this?BehatSpec/src/Extension/ErrorExtension/src/Tester/ErrorTester.php
line 89