-
-
Notifications
You must be signed in to change notification settings - Fork 1k
Substitute quotes with underscores for method name #1955
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
Conversation
Rails' SystemTestCase uses `method_name` to generate a filename for a screenshot, which is output along with the failure message. The filename for examples with single or double quotation marks retain the marks, making it tedious to copy-and-past the generated filename then manually escape it to use in a shell command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm happy to improve this, but I'd really like a spec covering this scenario, otherwise we might simplify it in future without realising.
Sounds good. I can get that in the next few days.
|
What do you think about just replacing the regex with |
I'd rather we only remove characters that would otherwise cause problems. |
Spec is up. I changed the |
Thanks, I've kicked the build to see if it'll go green and will assess it if it fails again. |
Substitute quotes with underscores for method name
Merged, thanks |
[skip ci]
[skip ci]
Rails' SystemTestCase uses
method_name
to generate a filename for a screenshot, which is output along with the failure message. The filename for examples with single or double quotation marks retain the marks, making it tedious to copy-and-past the generated filename then manually escape it to use in a shell command.