Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

specify whether the delimiter is a regex or not #58

Open
LukeANewton opened this issue Jan 29, 2020 · 0 comments
Open

specify whether the delimiter is a regex or not #58

LukeANewton opened this issue Jan 29, 2020 · 0 comments
Labels
low priority stuff that should be done, but isnt necessary

Comments

@LukeANewton
Copy link
Owner

There are some issues with specifying the delimiter in a compare command due to how String.split() works. split() always expects a regex, so any delimiter with a metacharacter that is treated as so.

For example, if I wanted to delimit my test cases with "*****" the user would need to type "*****" into the terminal, otherwise you would get an error. That is manageable, but it would be nice if you could explicitly choose whether or not your delimiter should be treated as a regex or literal.

We can use Pattern.quote(string) to force a string to be a literal for string.split(), but we require some way for the user to say whether they have a regex or literal delimiter. maybe use "-d" for literal delimiter, and "-rd" for regex delimiter? you could store the delimiter as normal in the DTO and add a field to specify whether the delimiter string is a regex or literal.

@LukeANewton LukeANewton added this to the Finished Project milestone Jan 29, 2020
@LukeANewton LukeANewton added this to To do in Project Development via automation Jan 29, 2020
@LukeANewton LukeANewton added the low priority stuff that should be done, but isnt necessary label Feb 10, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
low priority stuff that should be done, but isnt necessary
Projects
Development

No branches or pull requests

1 participant