'Verifies that the text of the specified element matches ``expected``.
This keyword works exactly like `Element Text Should Be` except that
the expected value can be given as a pattern that the text of the
element must match.
Pattern matching is similar as matching files in a shell, and it is
always case-sensitive. In the pattern, \'*\' matches anything and \'?\'
matches any single character.
Examples using ``${XML}`` structure from `Example`:
| Element Text Should Match | ${XML}       | t???   | xpath=first  |
| ${paragraph} =            | Get Element  | ${XML} | xpath=html/p |
| Element Text Should Match | ${paragraph} | Text with * and *. | normalize_whitespace=yes |'

def element_text_should_match(self, source, pattern, xpath='.', normalize_whitespace=False, message=None):

    text = self.get_element_text(source, xpath, normalize_whitespace)
    should_match(text, pattern, message, values=False)
