MDL-40842 behat: Reverting to backtrace catchall as xdebug warnings were being missed
[moodle.git] / lib / tests / behat / behat_hooks.php
index f487c8f..bbbe7cc 100644 (file)
@@ -250,7 +250,7 @@ class behat_hooks extends behat_base {
             // PHP debug messages.
             $phperrorxpath = "//div[@data-rel='phpdebugmessage']";
             // Any other backtrace.
             // PHP debug messages.
             $phperrorxpath = "//div[@data-rel='phpdebugmessage']";
             // Any other backtrace.
-            $othersxpath = "//ul[@data-rel='backtrace']";
+            $othersxpath = "//*[contains(., ': call to ')])[1]";
 
             $xpaths = array($exceptionsxpath, $debuggingxpath, $phperrorxpath, $othersxpath);
             $joinedxpath = implode(' | ', $xpaths);
 
             $xpaths = array($exceptionsxpath, $debuggingxpath, $phperrorxpath, $othersxpath);
             $joinedxpath = implode(' | ', $xpaths);