Add method to check if a string matches a regular expression

This PR adds a method to the `StringExpectation` class to test whether a `String` matches a given regular expression.