Regex Stackoverflow error with ExampleTables on Windows
Description
Regex Stackoverflow error with ExampleTables on Windows, which partially originate from a JDK bug (StackOverflow with regex alternation like (.|\s)* ). The fix that works for me:
// Avoid alternation by using DOTALL and .* instead of (.|\s)* PatternScenarioParser.java private Pattern patternToPullScenarioTableIntoGroupOne() { KeyWords keywords = configuration.keywords(); String table = keywords.examplesTable(); return compile("."table" s(.*)", DOTALL); }
Regex Stackoverflow error with ExampleTables on Windows, which partially originate from a JDK bug (StackOverflow with regex alternation like (.|\s)* ). The fix that works for me:
// Avoid alternation by using DOTALL and .* instead of (.|\s)*
PatternScenarioParser.java
private Pattern patternToPullScenarioTableIntoGroupOne() {
KeyWords keywords = configuration.keywords();
String table = keywords.examplesTable();
return compile("."table"
s(.*)", DOTALL);
}