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

Snake case drops numbers #8

Closed
magnhaug opened this issue Jul 14, 2015 · 2 comments
Closed

Snake case drops numbers #8

magnhaug opened this issue Jul 14, 2015 · 2 comments

Comments

@magnhaug
Copy link

The symbol v2Counter converted to snake_case turns into v_counter.
The same holds true for SCREAMING_SNAKE_CASE.
Tested on 4.0.135.445. I imagine this would be a quick fix?

@krasa
Copy link
Owner

krasa commented Jul 14, 2015

yes, it should be easy.

but not sure if it should put an underscore before the number or not...

v2Counter -> v2_counter
fooBar2 -> foo_bar2

or

v2Counter -> v_2_counter
fooBar2 -> foo_bar_2

2015-07-14 12:47 GMT+02:00 Magnus Haug notifications@github.com:

The symbol v2Counter converted to snake_case turns into v_counter.
The same holds true for SCREAMING_SNAKE_CASE.
Tested on 4.0.135.445. I imagine this would be a quick fix?


Reply to this email directly or view it on GitHub
#8.

@magnhaug
Copy link
Author

I think it all depends, and it's impossible to satisfy all use cases.
I.e. the test method names:
should_successfully_authenticate_on_v2_api
versus:
convert_1_foot_to_12_inches

But I'd be happy to see the bug fixed, no matter which solution you choose.
If I'm unhappy with an extra or missing underscore after a conversion, I'll just fix that manually later.

krasa added a commit that referenced this issue Oct 5, 2015
@krasa krasa closed this as completed in e633bf6 Oct 5, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants