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

fix from Color.name to Color.color_name #1751

Merged

Conversation

4geru
Copy link
Contributor

@4geru 4geru commented Sep 17, 2019

Color.name is not written in example code but Color.color_name is written in exampe. so fixed test codes.

https://github.com/faker-ruby/faker/blob/master/CHANGELOG.md#v162-2016-02-20

 → git grep  "Color\.name"
no results

examples code

Faker::Color.hex_color #=> "#31a785"

Faker::Color.color_name #=> "yellow"

Faker::Color.rgb_color #=> [54, 233, 67]

Faker::Color.hsl_color #=> [69.87, 0.66, 0.3]

Faker::Color.hsla_color #=> [154.77, 0.36, 0.9, 0.26170574657729073]

reference : https://github.com/faker-ruby/faker/blob/master/doc/default/color.md

@4geru 4geru force-pushed the fix_from_Color_name_to_Color_color_name branch 2 times, most recently from 23c04d2 to 5d21e53 Compare September 17, 2019 14:59
Copy link
Member

@bpleslie bpleslie left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not sure how these were passing before 🤔

Good catch! Thanks!

@4geru
Copy link
Contributor Author

4geru commented Sep 20, 2019

Exactly! Thanks for review comment. I tried to check it.

Faker::Color.name means class name but it is return string class, so it seems pass test. :(

>   Faker::Config.locale = 'en'
> Faker::Color.name
=> "Faker::Color"
> Faker::Color.color_name
=> "yellow"

@4geru 4geru force-pushed the fix_from_Color_name_to_Color_color_name branch from 5d21e53 to fb6fed2 Compare September 22, 2019 15:46
@4geru
Copy link
Contributor Author

4geru commented Sep 23, 2019

@vbrazo plz review this pull request 🙇

Copy link
Member

@vbrazo vbrazo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this 👍

@vbrazo vbrazo merged commit 4d62e8f into faker-ruby:master Sep 25, 2019
sanikkenway added a commit to sanikkenway/faker that referenced this pull request Sep 26, 2019
fix from Color.name to Color.color_name (faker-ruby#1751)
michebble pushed a commit to michebble/faker that referenced this pull request Feb 16, 2020
davidmorton0 pushed a commit to davidmorton0/faker that referenced this pull request Jul 12, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants