Change error class handling in FPF to set classes on elements returned by the respective XPath expressions, not the original elements, closes #768