Open drkstr101 opened 4 years ago
We should consider integrating with the internal parser/matcher instead of using our own:
Yes I think you are right. It would be ideal if step matching was consistent with underlying library used to execute the tests.
Support for Cucumber Expressions has been added to recent versions of cucumber-jvm, which cause the stepmatcher to fail in the current release. It took those folks a little over a year to implement the feature, so it seems like it will be quite involved.
This work should most likely happen as a separate point release after next, which addresses the immediate issue of the validation routine bailing with a runtime exception. This is accomplished by
checking the first character of thecatching any PatternSyntaxException that results from the match and defaulting to false (no match found). The next step would be to attempt to parse theannotationValue
prior to attempting the regex matchannotationValue
as a Cucumber Expression to see if it matches the provided step description.