[behat] Fixes the method to get screenshots on failure