T
Thomas Koenig
Assume I have a regexp, /^(hello)|(goodbye)$/ for example.
I want to see wether a particular string matches part of that
particular regexp, so "", "h", "he", "hel", "hell", "hello", "g",
"go", "goo" "good", "goodb", "goodby" and "goodbye" would be ok,
and anything else wouldn't.
I could hand-craft this example easily enough, but it grows
tedious and error-prone for more general regular expressions,
and automation would be much preferred.
Ideas?
I want to see wether a particular string matches part of that
particular regexp, so "", "h", "he", "hel", "hell", "hello", "g",
"go", "goo" "good", "goodb", "goodby" and "goodbye" would be ok,
and anything else wouldn't.
I could hand-craft this example easily enough, but it grows
tedious and error-prone for more general regular expressions,
and automation would be much preferred.
Ideas?