Creating a new locale. Tests are failing.

82 views
Skip to first unread message

Stefán Vignir Skarphéðinsson

unread,
Feb 12, 2014, 7:03:49 PM2/12/14
to ruby-...@googlegroups.com
First of all, I'm not a Ruby developer by trade, and unit testing is a new thing for me.

I decided to try to create an Icelandic locale for Faker. What I've added right now are country names and ca. 100 common first names, but when running rake test the test fails:

[ 2/75] TesetEnUsLocale#test_us_phone_methods_return_nil_for_nil_locale/Library/Ruby/Gems/2.0.0/gems/i18n-0.6.9/lib/i18n.rb:361: warning: instance variable @unenforced_available_locales_deprecation not initialized

[deprecated] I18n.enforce_available_locales will default to true in the future. If you really want to skip validation of your locale you can set I18n.enforce_available_locales = false to avoid this message.

[75/75] TestLocale#test_translation_fallback = 0.00 s                                                                                 

  1) Failure:

test_translation_fallback(TestLocale) [/Users/stefanvignir/github/faker/test/test_locale.rb:33]:

<"Jón"> expected but was

<"Aaliyah">.

Aaliyah is in en.yml, but not in is.yml. — And this particular test seems to be using the en.yml and en-bork.yml.

So I'm stuck. Can I get any help? :)


Regards,
Stefan Vignir

Conrad Taylor

unread,
Feb 14, 2014, 4:37:24 PM2/14/14
to ruby-...@googlegroups.com
Hi, I recommended using the faker gem which can be found here for adding enhancements:


--
You received this message because you are subscribed to the Google Groups "Ruby Faker" group.
To unsubscribe from this group and stop receiving emails from it, send an email to ruby-faker+...@googlegroups.com.
To post to this group, send email to ruby-...@googlegroups.com.
Visit this group at http://groups.google.com/group/ruby-faker.
For more options, visit https://groups.google.com/groups/opt_out.


Think different and code well,

Conrad Taylor

Stefán Vignir Skarphéðinsson

unread,
Feb 14, 2014, 4:40:08 PM2/14/14
to ruby-...@googlegroups.com
Hi, I recommended using the faker gem which can be found here for adding enhancements:

Ah! Thanks for the heads up!

Stefán Vignir Skarphéðinsson

unread,
Feb 14, 2014, 4:38:51 PM2/14/14
to ruby-...@googlegroups.com
Oh. It looks like I found the bug while waiting for my mail to go through moderation.

I’m going to spend some time making the company name generator a bit more comprehensive before making a pull request.  

Reply all
Reply to author
Forward
0 new messages