faker 2.17.0 → 2.20.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (128) hide show
  1. checksums.yaml +4 -4
  2. data/CHANGELOG.md +95 -2
  3. data/README.md +22 -4
  4. data/lib/faker/books/the_kingkiller_chronicle.rb +61 -0
  5. data/lib/faker/creature/bird.rb +203 -0
  6. data/lib/faker/default/code.rb +1 -1
  7. data/lib/faker/default/commerce.rb +28 -0
  8. data/lib/faker/default/company.rb +5 -7
  9. data/lib/faker/default/crypto.rb +13 -0
  10. data/lib/faker/default/emotion.rb +33 -0
  11. data/lib/faker/default/finance.rb +13 -0
  12. data/lib/faker/default/food.rb +13 -0
  13. data/lib/faker/default/hobby.rb +22 -0
  14. data/lib/faker/default/id_number.rb +34 -0
  15. data/lib/faker/default/internet.rb +40 -16
  16. data/lib/faker/default/lorem.rb +0 -4
  17. data/lib/faker/default/nation.rb +0 -3
  18. data/lib/faker/default/omniauth.rb +45 -1
  19. data/lib/faker/default/placeholdit.rb +9 -9
  20. data/lib/faker/default/religion.rb +6 -0
  21. data/lib/faker/default/science.rb +108 -0
  22. data/lib/faker/default/string.rb +0 -3
  23. data/lib/faker/default/tea.rb +41 -0
  24. data/lib/faker/default/time.rb +0 -2
  25. data/lib/faker/games/dota.rb +13 -0
  26. data/lib/faker/games/witcher.rb +39 -0
  27. data/lib/faker/japanese_media/fullmetal_alchemist_brotherhood.rb +48 -0
  28. data/lib/faker/japanese_media/kamen_rider.rb +102 -0
  29. data/lib/faker/locations/australia.rb +47 -0
  30. data/lib/faker/music/hiphop.rb +3 -3
  31. data/lib/faker/music/music.rb +12 -0
  32. data/lib/faker/religion/bible.rb +50 -0
  33. data/lib/faker/tv_shows/brooklyn_nine_nine.rb +38 -0
  34. data/lib/faker/tv_shows/michael_scott.rb +0 -3
  35. data/lib/faker/tv_shows/supernatural.rb +48 -0
  36. data/lib/faker/tv_shows/the_office.rb +37 -0
  37. data/lib/faker/version.rb +2 -2
  38. data/lib/locales/ar.yml +5 -1
  39. data/lib/locales/de-AT.yml +2 -2
  40. data/lib/locales/de.yml +7 -3
  41. data/lib/locales/en/address.yml +2 -3
  42. data/lib/locales/en/animal.yml +1 -1
  43. data/lib/locales/en/australia.yml +108 -0
  44. data/lib/locales/en/bible.yml +90 -0
  45. data/lib/locales/en/bird.yml +1281 -0
  46. data/lib/locales/en/book.yml +487 -3
  47. data/lib/locales/en/brooklyn_nine_nine.yml +35 -0
  48. data/lib/locales/en/cat.yml +1 -1
  49. data/lib/locales/en/coffee.yml +1 -1
  50. data/lib/locales/en/commerce.yml +17 -0
  51. data/lib/locales/en/community.yml +17 -17
  52. data/lib/locales/en/dota.yml +7 -0
  53. data/lib/locales/en/dune.yml +266 -397
  54. data/lib/locales/en/emotion.yml +480 -0
  55. data/lib/locales/en/finance.yml +21 -0
  56. data/lib/locales/en/fma_brotherhood.yml +78 -0
  57. data/lib/locales/en/food.yml +1054 -10
  58. data/lib/locales/en/game.yml +12 -0
  59. data/lib/locales/en/hobby.yml +171 -0
  60. data/lib/locales/en/horse.yml +2 -2
  61. data/lib/locales/en/internet.yml +108 -3
  62. data/lib/locales/en/kamen_rider.yml +452 -0
  63. data/lib/locales/en/kpop.yml +7 -7
  64. data/lib/locales/en/lovecraft.yml +76 -6
  65. data/lib/locales/en/mountain.yml +14 -1
  66. data/lib/locales/en/music.yml +152 -142
  67. data/lib/locales/en/science.yml +481 -3
  68. data/lib/locales/en/space.yml +1 -1
  69. data/lib/locales/en/stranger_thing.yml +1 -1
  70. data/lib/locales/en/super_smash_bros.yml +5 -2
  71. data/lib/locales/en/supernatural.yml +141 -0
  72. data/lib/locales/en/tea.yml +172 -0
  73. data/lib/locales/en/the_kingkiller_chronicle.yml +56 -0
  74. data/lib/locales/en/the_office.yml +86 -0
  75. data/lib/locales/en/touhou.yml +1 -1
  76. data/lib/locales/en/witcher.yml +37 -0
  77. data/lib/locales/en-US.yml +2 -2
  78. data/lib/locales/es-AR.yml +1 -4
  79. data/lib/locales/fr/address.yml +21 -0
  80. data/lib/locales/fr/animal.yml +5 -0
  81. data/lib/locales/fr/appliance.yml +4 -0
  82. data/lib/locales/fr/book.yml +7 -0
  83. data/lib/locales/fr/color.yml +4 -0
  84. data/lib/locales/fr/company.yml +17 -0
  85. data/lib/locales/fr/compass.yml +23 -0
  86. data/lib/locales/fr/demographic.yml +4 -0
  87. data/lib/locales/fr/gender.yml +6 -0
  88. data/lib/locales/fr/internet.yml +5 -0
  89. data/lib/locales/fr/lorem.yml +5 -0
  90. data/lib/locales/fr/measurement.yml +7 -0
  91. data/lib/locales/fr/name.yml +21 -0
  92. data/lib/locales/fr/phone_number.yml +7 -0
  93. data/lib/locales/fr/pokemon.yml +7 -0
  94. data/lib/locales/fr.yml +0 -118
  95. data/lib/locales/ja/README.md +13 -0
  96. data/lib/locales/ja/address.yml +120539 -0
  97. data/lib/locales/ja/ancient.yml +4 -0
  98. data/lib/locales/ja/animal.yml +5 -0
  99. data/lib/locales/ja/bank.yml +4 -0
  100. data/lib/locales/ja/book.yml +7 -0
  101. data/lib/locales/ja/cat.yml +5 -0
  102. data/lib/locales/ja/coffee.yml +4 -0
  103. data/lib/locales/ja/color.yml +4 -0
  104. data/lib/locales/ja/commerce.yml +11 -0
  105. data/lib/locales/ja/company.yml +8 -0
  106. data/lib/locales/ja/dog.yml +5 -0
  107. data/lib/locales/ja/food.yml +4 -0
  108. data/lib/locales/ja/gender.yml +4 -0
  109. data/lib/locales/ja/lorem.yml +9 -0
  110. data/lib/locales/ja/name.yml +13 -0
  111. data/lib/locales/ja/overwatch.yml +5 -0
  112. data/lib/locales/ja/phone_number.yml +7 -0
  113. data/lib/locales/ja/pokemon.yml +7 -0
  114. data/lib/locales/ja/restaurant.yml +11 -0
  115. data/lib/locales/ja/space.yml +5 -0
  116. data/lib/locales/ja/studio_ghibli.yml +112 -0
  117. data/lib/locales/ja/subscription.yml +8 -0
  118. data/lib/locales/ja/super_mario.yml +9 -0
  119. data/lib/locales/ja/super_smash_bros.yml +8 -0
  120. data/lib/locales/ja/university.yml +9 -0
  121. data/lib/locales/ja/zelda.yml +5 -0
  122. data/lib/locales/lt.yml +35 -0
  123. data/lib/locales/lv.yml +1 -1
  124. data/lib/locales/mi-NZ.yml +281 -0
  125. data/lib/locales/pt-BR.yml +7 -1
  126. data/lib/locales/ru.yml +39 -0
  127. metadata +94 -20
  128. data/lib/locales/ja.yml +0 -118
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 057f887ea424391e1a5e3c354c93435061ed58b21e6d96c8406a3caa2c53a114
4
- data.tar.gz: 5c33ffaafb3374a76feaab9f83f03e3815e1fa5503b4aeddd40726a2fc3f5d41
3
+ metadata.gz: 263e2d15636da915718fec1db63ac9595f87b2a075ddaa0e536ce89a57523b81
4
+ data.tar.gz: 677c2ee1537ece0e18820f72ac1a528c3581f60e298d51c125ff9d673d6e6022
5
5
  SHA512:
6
- metadata.gz: d117b98af058311ad015475303910e4d0761119eb171d544760d3687fb8b2eb8ffe791c44d39db1bd5244260fb8ca04f8e19923fdb1edee4dc4876b44388bf5e
7
- data.tar.gz: cbf27dfec7b156d23eabb2136b2a265baee51b7673e8ae1ff063310fbfdc57402558574d94648ee764ba8ecc1ed732704ddfec70ec6118eaf4fb1b536cb5c039
6
+ metadata.gz: ad45cb3518237236a31bf97d0bbe48214cef9ef1debca67f3d4ea5cb0c105c9d045d37fd22f33cc9da90be89ddb1ce8113d9a016f4f18098a679e5e9e53521d0
7
+ data.tar.gz: 449074010c194137d0f9bc77e4730f09058559016e780a4ca78c1bcb4f650002e22f8c6af0668f1f1d6ee43e25f11793855df496095ab0e314c8a24923daba29
data/CHANGELOG.md CHANGED
@@ -1,6 +1,99 @@
1
1
  # Change Log
2
2
 
3
- ## [v2.17.0](https://github.com/faker-ruby/faker/tree/v2.17.0) (2020-03-10)
3
+ ## [v2.19.0](https://github.com/faker-ruby/faker/tree/v2.19.0) (2021-08-22)
4
+
5
+ ## Bug/Fixes
6
+
7
+ - [PR #2356](https://github.com/faker-ruby/faker/pull/2356) fix broken link for placeholdit [@lilisako](https://github.com/lilisako)
8
+ - [PR #2351](https://github.com/faker-ruby/faker/pull/2351) Fix spanish organisation number [@laulujan](https://github.com/laulujan)
9
+
10
+ ## Feature Request
11
+
12
+ - [PR #2371](https://github.com/faker-ruby/faker/pull/2371) Add supernatural TV show [@vin1cius](https://github.com/vin1cius)
13
+ - [PR #2369](https://github.com/faker-ruby/faker/pull/2369) Added more Science examples - science branches, modifiers and tools [@itay-grudev](https://github.com/itay-grudev)
14
+ - [PR #2361](https://github.com/faker-ruby/faker/pull/2361) Add ethnic category to the food generator [@wolwire](https://github.com/wolwire)
15
+ - [PR #2359](https://github.com/faker-ruby/faker/pull/2359) add stock_market to finance Faker::Finance [@lilisako](https://github.com/lilisako)
16
+ - [PR #2341](https://github.com/faker-ruby/faker/pull/2341) add Hobby to default [@rohanphillips](https://github.com/rohanphillips)
17
+ - [PR #2324](https://github.com/faker-ruby/faker/pull/2324) Add Faker::Emotion.word [@jayqui](https://github.com/jayqui)
18
+ - [PR #2320](https://github.com/faker-ruby/faker/pull/2320) Add Faker::TvShows::TheOffice [@sandylcruz](https://github.com/sandylcruz)
19
+ - [PR #2245](https://github.com/faker-ruby/faker/pull/2245) Add Faker::Australia class [@astley92](https://github.com/astley92)
20
+ - [PR #1731](https://github.com/faker-ruby/faker/pull/1731) add brand, vendor support to commerce [@ashishra0](https://github.com/ashishra0)
21
+
22
+ ## Update locales
23
+
24
+ - [PR #2343](https://github.com/faker-ruby/faker/pull/2343) Minor typo fixes to Community quotes [@sunny](https://github.com/sunny)
25
+ - [PR #2340](https://github.com/faker-ruby/faker/pull/2340) Add JapaneseMedia StudioGhibli for locals/ja.yml [@ryogift](https://github.com/ryogift)
26
+ - [PR #2339](https://github.com/faker-ruby/faker/pull/2339) Various locale specific and other fixes for faker [@psibi](https://github.com/psibi)
27
+ - [PR #2338](https://github.com/faker-ruby/faker/pull/2338) Add Kazuya to Faker::Games::SuperSmashBros [@boardfish](https://github.com/boardfish)
28
+ - [PR #2333](https://github.com/faker-ruby/faker/pull/2333) add FR translation for animals [@cprodhomme](https://github.com/cprodhomme)
29
+ - [PR #2329](https://github.com/faker-ruby/faker/pull/2329) Fix Faker::Color.color_name for Japanese [@yujideveloper](https://github.com/yujideveloper)
30
+ - [PR #2327](https://github.com/faker-ruby/faker/pull/2327) Remove trailing spaces from translations [@michebble](https://github.com/michebble)
31
+ - [PR #2326](https://github.com/faker-ruby/faker/pull/2326) Faker::Address.postcode (locale=ja) should contains hyphen [@gongo](https://github.com/gongo)
32
+
33
+ ## Update local dependencies
34
+
35
+ - Update rubocop requirement from = 1.18.3 to = 1.18.4 (#2362)
36
+ - Update rake requirement from = 13.0.3 to = 13.0.6 (#2357)
37
+ - Update rubocop requirement from = 1.18.1 to = 1.18.3 (#2353)
38
+ - Update rubocop requirement from = 1.17.0 to = 1.18.1 (#2346)
39
+ - Update rubocop requirement from = 1.16.0 to = 1.17.0 (#2337)
40
+ - Update test-unit requirement from = 3.4.2 to = 3.4.4 (#2334)
41
+ - Update rubocop requirement from = 1.15.0 to = 1.16.0 (#2332)
42
+ - Update test-unit requirement from = 3.4.1 to = 3.4.2 (#2331)
43
+ - Update rubocop requirement from = 1.14.0 to = 1.15.0 (#2325)
44
+
45
+ ------------------------------------------------------------------------------
46
+
47
+ ## [v2.18.0](https://github.com/faker-ruby/faker/tree/v2.18.0) (2021-05-15)
48
+
49
+ ## Bug/Fixes
50
+
51
+ - [PR #2300](https://github.com/faker-ruby/faker/pull/2300) Fix space.company by adding missing quote [@koic](https://github.com/koic)
52
+ - [PR #2044](https://github.com/faker-ruby/faker/pull/2044) Workaround for cc-test-reporter with SimpleCov 0.18 [@koic](https://github.com/koic)
53
+
54
+ ## Chores
55
+
56
+ - [PR #2316](https://github.com/faker-ruby/faker/pull/2316) Fix typo in test method [@yujideveloper](https://github.com/yujideveloper)
57
+
58
+ ## Documentation
59
+
60
+ - [PR #2290](https://github.com/faker-ruby/faker/pull/2290) Fix typo [@d-holbach](https://github.com/d-holbach)
61
+ - [PR #2282](https://github.com/faker-ruby/faker/pull/2282) fixed small typo [@koic](https://github.com/koic)
62
+
63
+ ## Feature Request
64
+
65
+ - [PR #2301](https://github.com/faker-ruby/faker/pull/2301) Add Faker::IDNumber.croatian_id method [@lovro-bikic](https://github.com/lovro-bikic)
66
+ - [PR #2299](https://github.com/faker-ruby/faker/pull/2299) Add birds [@brotherjack](https://github.com/brotherjack)
67
+ - [PR #2295](https://github.com/faker-ruby/faker/pull/2295) Add more methods to the Witcher class [@marcelobarreto](https://github.com/marcelobarreto)
68
+ - [PR #2289](https://github.com/faker-ruby/faker/pull/2289) Increase french entropy [@meuble](https://github.com/meuble)
69
+ - [PR #2287](https://github.com/faker-ruby/faker/pull/2287) Add Crypto.sha512 [@crondaemon](https://github.com/crondaemon)
70
+ - [PR #2190](https://github.com/faker-ruby/faker/pull/2190) Add Faker::Tea [@snood1205](https://github.com/snood1205)
71
+ - [PR #2175](https://github.com/faker-ruby/faker/pull/2175) Add two generators to Faker::Science [@RubyHuntsman](https://github.com/RubyHuntsman)
72
+ - [PR #1910](https://github.com/faker-ruby/faker/pull/1910) Add Faker::Music#mambo_no_5, a Generator for Random First Names that Appear in Lou Bega's Mambo No. 5 [@NickyEXE](https://github.com/NickyEXE)
73
+
74
+ ## Update locales
75
+
76
+ - [PR #2321](https://github.com/faker-ruby/faker/pull/2321) Canadian area code 226 included in array of US area codes [@jgarber623](https://github.com/jgarber623)
77
+ - [PR #2317](https://github.com/faker-ruby/faker/pull/2317) Fix ci for es-AR [@yujideveloper](https://github.com/yujideveloper)
78
+ - [PR #2315](https://github.com/faker-ruby/faker/pull/2315) Split JA translation file into one file per class [@yujideveloper](https://github.com/yujideveloper)
79
+ - [PR #2313](https://github.com/faker-ruby/faker/pull/2313) Add Japanese translation for Faker::Subscription [@yujideveloper](https://github.com/yujideveloper)
80
+ - [PR #2311](https://github.com/faker-ruby/faker/pull/2311) add yoda quotes to russian locale [@aka-nez](https://github.com/aka-nez)
81
+ - [PR #2297](https://github.com/faker-ruby/faker/pull/2297) add Japanese actual zipcodes in locals/ja.yml [@POPPIN-FUMI](https://github.com/POPPIN-FUMI)
82
+ - [PR #2291](https://github.com/faker-ruby/faker/pull/2291) Add Commerce for Japanese [@ima1zumi](https://github.com/ima1zumi)
83
+ - [PR #2285](https://github.com/faker-ruby/faker/pull/2285) Fix update Brazilian phone country code [@ricardopacheco](https://github.com/ricardopacheco)
84
+ - [PR #2154](https://github.com/faker-ruby/faker/pull/2154) Cleanup books. Add Fantasy::Tolkien to README. [@mathisto](https://github.com/mathisto)
85
+
86
+ ## Update local dependencies
87
+
88
+ - Update rubocop requirement from = 1.13.0 to = 1.14.0 (#2314)
89
+ - Upgrade to GitHub-native Dependabot (#2310)
90
+ - Update rubocop requirement from = 1.12.1 to = 1.13.0 (#2305)
91
+ - Update test-unit requirement from = 3.4.0 to = 3.4.1 (#2303)
92
+ - Update pry requirement from = 0.14.0 to = 0.14.1 (#2298)
93
+ - Update rubocop requirement from = 1.12.0 to = 1.12.1 (#2294)
94
+ - Update rubocop requirement from = 1.11.0 to = 1.12.0 (#2288)
95
+
96
+ ## [v2.17.0](https://github.com/faker-ruby/faker/tree/v2.17.0) (2021-03-10)
4
97
 
5
98
  ## Chores
6
99
 
@@ -30,7 +123,7 @@
30
123
 
31
124
  ------------------------------------------------------------------------------
32
125
 
33
- ## [v2.16.0](https://github.com/faker-ruby/faker/tree/v2.16.0) (2020-02-09)
126
+ ## [v2.16.0](https://github.com/faker-ruby/faker/tree/v2.16.0) (2021-02-09)
34
127
 
35
128
  ## Chores
36
129
 
data/README.md CHANGED
@@ -27,6 +27,7 @@ development.
27
27
  - [Default](#default)
28
28
  - [Blockchain](#blockchain)
29
29
  - [Books](#books)
30
+ - [Fantasy](#fantasy)
30
31
  - [Creature](#creature)
31
32
  - [Games](#games)
32
33
  - [Japanese Media](#japanese-media)
@@ -135,6 +136,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
135
136
  - [Faker::Boolean](doc/default/boolean.md)
136
137
  - [Faker::BossaNova](doc/default/bossa_nova.md)
137
138
  - [Faker::Business](doc/default/business.md)
139
+ - [Faker::Camera](doc/default/camera.md)
138
140
  - [Faker::Cannabis](doc/default/cannabis.md)
139
141
  - [Faker::ChileRut](doc/default/chile_rut.md)
140
142
  - [Faker::ChuckNorris](doc/default/chuck_norris.md)
@@ -160,6 +162,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
160
162
  - [Faker::Drone](doc/drone/drone.md)
161
163
  - [Faker::Educator](doc/default/educator.md)
162
164
  - [Faker::ElectricalComponents](doc/default/electrical_components.md)
165
+ - [Faker::Emotion](doc/default/emotion.md)
163
166
  - [Faker::Esport](doc/default/esport.md)
164
167
  - [Faker::File](doc/default/file.md)
165
168
  - [Faker::Fillmurray](doc/default/fillmurray.md)
@@ -170,6 +173,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
170
173
  - [Faker::GreekPhilosophers](doc/default/greek_philosophers.md)
171
174
  - [Faker::Hacker](doc/default/hacker.md)
172
175
  - [Faker::Hipster](doc/default/hipster.md)
176
+ - [Faker::Hobby](doc/default/hobby.md)
173
177
  - [Faker::House](doc/default/house.md)
174
178
  - [Faker::IDNumber](doc/default/id_number.md)
175
179
  - [Faker::IndustrySegments](doc/default/industry_segments.md)
@@ -206,6 +210,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
206
210
  - [Faker::Stripe](doc/default/stripe.md)
207
211
  - [Faker::Subscription](doc/default/subscription.md)
208
212
  - [Faker::Superhero](doc/default/superhero.md)
213
+ - [Faker::Tea](doc/default/tea.md)
209
214
  - [Faker::Team](doc/default/team.md)
210
215
  - [Faker::Time](doc/default/time.md)
211
216
  - [Faker::Twitter](doc/default/twitter.md)
@@ -226,9 +231,14 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
226
231
  - [Faker::Books::CultureSeries](doc/books/culture_series.md)
227
232
  - [Faker::Books::Dune](doc/books/dune.md)
228
233
  - [Faker::Books::Lovecraft](doc/books/lovecraft.md)
234
+ - [Faker::Books::TheKingkillerChronicle](doc/books/the_kingkiller_chronicle.md)
235
+
236
+ ### Fantasy
237
+ - [Faker::Fantasy::Tolkien](doc/fantasy/tolkien.md)
229
238
 
230
239
  ### Creature
231
240
  - [Faker::Creature::Animal](doc/creature/animal.md)
241
+ - [Faker::Creature::Bird](doc/creature/bird.md)
232
242
  - [Faker::Creature::Cat](doc/creature/cat.md)
233
243
  - [Faker::Creature::Dog](doc/creature/dog.md)
234
244
  - [Faker::Creature::Horse](doc/creature/horse.md)
@@ -266,6 +276,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
266
276
  - [Faker::JapaneseMedia::Naruto](doc/japanese_media/naruto.md)
267
277
  - [Faker::JapaneseMedia::Doraemon](doc/japanese_media/doraemon.md)
268
278
  - [Faker::JapaneseMedia::Conan](doc/japanese_media/conan.md)
279
+ - [Faker::JapaneseMedia::FmaBrotherhood](doc/japanese_media/fullmetal_alchemist_brotherhood.md)
269
280
 
270
281
  ### Movies
271
282
  - [Faker::Movie](doc/movies/movie.md)
@@ -285,7 +296,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
285
296
  ### Music
286
297
  - [Faker::Music](doc/music/music.md)
287
298
  - [Faker::Music::GratefulDead](doc/music/grateful_dead.md)
288
- - [Faker::Music::HipHop](doc/music/hiphop.md)
299
+ - [Faker::Music::Hiphop](doc/music/hiphop.md)
289
300
  - [Faker::Music::Opera](doc/music/opera.md)
290
301
  - [Faker::Music::PearlJam](doc/music/pearl_jam.md)
291
302
  - [Faker::Music::Phish](doc/music/phish.md)
@@ -310,6 +321,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
310
321
  - [Faker::TvShows::BigBangTheory](doc/tv_shows/big_bang_theory.md)
311
322
  - [Faker::TvShows::BojackHorseman](doc/tv_shows/bojack_horseman.md)
312
323
  - [Faker::TvShows::BreakingBad](doc/tv_shows/breaking_bad.md)
324
+ - [Faker::TvShows::BrooklynNineNine](doc/tv_shows/brooklyn_nine_nine.md)
313
325
  - [Faker::TvShows::Buffy](doc/tv_shows/buffy.md)
314
326
  - [Faker::TvShows::Community](doc/tv_shows/community.md)
315
327
  - [Faker::TvShows::DrWho](doc/tv_shows/dr_who.md)
@@ -333,6 +345,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'mast
333
345
  - [Faker::TvShows::Stargate](doc/tv_shows/stargate.md)
334
346
  - [Faker::TvShows::StrangerThings](doc/tv_shows/stranger_things.md)
335
347
  - [Faker::TvShows::Suits](doc/tv_shows/suits.md)
348
+ - [Faker::TvShows::Supernatural](doc/tv_shows/supernatural.md)
336
349
  - [Faker::TvShows::TheExpanse](doc/tv_shows/the_expanse.md)
337
350
  - [Faker::TvShows::TheFreshPrinceOfBelAir](doc/tv_shows/the_fresh_prince_of_bel_air.md)
338
351
  - [Faker::TvShows::TheITCrowd](doc/tv_shows/the_it_crowd.md)
@@ -345,9 +358,14 @@ Since you may want to make addresses and other types of data look different
345
358
  depending on where in the world you are (US postal codes vs. UK postal codes,
346
359
  for example), Faker uses the I18n gem to store strings (like state names) and
347
360
  formats (US postal codes are NNNNN while UK postal codes are AAN NAA),
348
- allowing you to get different formats by switching locales. Just set
349
- Faker::Config.locale to the locale you want, and Faker will take care of the
350
- rest.
361
+ allowing you to get different formats by switching locales.
362
+ Just set the locale you want as shown below, and Faker will take care of the rest.
363
+
364
+ ```ruby
365
+ Faker::Config.locale = 'es'
366
+ # or
367
+ Faker::Config.locale = :es
368
+ ```
351
369
 
352
370
  If your locale doesn't already exist, create it in the `lib/locales` directory
353
371
  and you can then override or add elements to suit your needs. See more about how to
@@ -0,0 +1,61 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Faker
4
+ class Books
5
+ class TheKingkillerChronicle < Base
6
+ class << self
7
+ ##
8
+ # Produces the name of a The Kingkiller Chronicle book.
9
+ #
10
+ # @return [String]
11
+ #
12
+ # @example
13
+ # Faker::Books::TheKingkillerChronicle.book #=> "The Name of the Wind"
14
+ #
15
+ # @faker.version next
16
+ def book
17
+ fetch('books.the_kingkiller_chronicle.books')
18
+ end
19
+
20
+ ##
21
+ # Produces the name of a The Kingkiller Chronicle character.
22
+ #
23
+ # @return [String]
24
+ #
25
+ # @example
26
+ # Faker::Books::TheKingkillerChronicle.character #=> "Kvothe"
27
+ #
28
+ # @faker.version next
29
+ def character
30
+ fetch('books.the_kingkiller_chronicle.characters')
31
+ end
32
+
33
+ ##
34
+ # Produces the name of a The Kingkiller Chronicle creature.
35
+ #
36
+ # @return [String]
37
+ #
38
+ # @example
39
+ # Faker::Books::TheKingkillerChronicle.creature #=> "Scrael"
40
+ #
41
+ # @faker.version next
42
+ def creature
43
+ fetch('books.the_kingkiller_chronicle.creatures')
44
+ end
45
+
46
+ ##
47
+ # Produces the name of a The Kingkiller Chronicle location.
48
+ #
49
+ # @return [String]
50
+ #
51
+ # @example
52
+ # Faker::Books::TheKingkillerChronicle.location #=> "Tarbean"
53
+ #
54
+ # @faker.version next
55
+ def location
56
+ fetch('books.the_kingkiller_chronicle.locations')
57
+ end
58
+ end
59
+ end
60
+ end
61
+ end
@@ -0,0 +1,203 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Faker
4
+ class Creature
5
+ class Bird < Base
6
+ flexible :bird
7
+
8
+ class << self
9
+ ##
10
+ # Produces a random common family name of a bird.
11
+ #
12
+ # @return [String]
13
+ #
14
+ # @example
15
+ # Faker::Creature::Bird.common_family_name #=> "Owls"
16
+ #
17
+ # @faker.version next
18
+ def common_family_name
19
+ fetch('creature.bird.common_family_name')
20
+ end
21
+
22
+ ##
23
+ # Produces a random common taxonomic order from the class Aves
24
+ #
25
+ # @return [String]
26
+ #
27
+ # @example
28
+ # Faker::Creature::Bird.order #=> "Passeriformes"
29
+ #
30
+ # @faker.version next
31
+ def order
32
+ orders = I18n.translate('faker.creature.bird.order_common_map').keys
33
+ sample(orders).to_s
34
+ end
35
+
36
+ ##
37
+ # Produces a random bird anatomy word
38
+ #
39
+ # @return [String]
40
+ #
41
+ # @example
42
+ # Faker::Creature::Bird.anatomy #=> "rump"
43
+ #
44
+ # @faker.version next
45
+ def anatomy
46
+ fetch('creature.bird.anatomy')
47
+ end
48
+
49
+ ##
50
+ # Produces a random, past tensed bird anatomy word
51
+ #
52
+ # @return [String]
53
+ #
54
+ # @example
55
+ # Faker::Creature::Bird.anatomy #=> "breasted"
56
+ #
57
+ # @faker.version next
58
+ def anatomy_past_tense
59
+ fetch('creature.bird.anatomy_past_tense')
60
+ end
61
+
62
+ ##
63
+ # Produces a random geographical word used in describing birds
64
+ #
65
+ # @return [String]
66
+ #
67
+ # @example
68
+ # Faker::Creature::Bird.geo #=> "Eurasian"
69
+ #
70
+ # @faker.version next
71
+ def geo
72
+ fetch('creature.bird.geo')
73
+ end
74
+
75
+ ##
76
+ # Produces a random color word used in describing birds
77
+ #
78
+ # @return [String]
79
+ #
80
+ # @example
81
+ # Faker::Creature::Bird.color #=> "ferruginous"
82
+ #
83
+ # @faker.version next
84
+ def color
85
+ fetch('creature.bird.colors')
86
+ end
87
+
88
+ ##
89
+ # Produces a random adjective used to described birds
90
+ #
91
+ # @return [String]
92
+ #
93
+ # @example
94
+ # Faker::Creature::Bird.adjective #=> 'common'
95
+ #
96
+ # @faker.version next
97
+ def adjective
98
+ fetch('creature.bird.adjectives')
99
+ end
100
+
101
+ ##
102
+ # Produces a random emotional adjective NOT used to described birds
103
+ # ...but could be
104
+ #
105
+ # @return [String]
106
+ #
107
+ # @example
108
+ # Faker::Creature::Bird.emotional_adjective #=> 'cantankerous'
109
+ #
110
+ # @faker.version next
111
+ def emotional_adjective
112
+ fetch('creature.bird.emotional_adjectives')
113
+ end
114
+
115
+ ##
116
+ # Produces a random adjective NOT used to described birds
117
+ # ...but probably shouldn't
118
+ #
119
+ # @return [String]
120
+ #
121
+ # @example
122
+ # Faker::Creature::Bird.silly_adjective #=> 'drunk'
123
+ #
124
+ # @faker.version next
125
+ def silly_adjective
126
+ fetch('creature.bird.silly_adjectives')
127
+ end
128
+
129
+ ##
130
+ # Produces a random common name for a bird
131
+ #
132
+ # @param [String | Symbol | nil] tax_order Tax
133
+ # @return [String]
134
+ # @raises TypeError If `tax_order` cannot be converted into a Symbol
135
+ # @raises ArgumentError If `tax_order` is not a valid taxonomic order
136
+ #
137
+ # @example
138
+ # Faker::Creature::Bird.common_name #=> 'wren'
139
+ #
140
+ # @faker.version next
141
+ def common_name(tax_order = nil)
142
+ map = translate('faker.creature.bird.order_common_map')
143
+ if tax_order.nil?
144
+ sample(map.values.flatten).downcase
145
+ else
146
+ raise TypeError, 'tax_order parameter must be symbolizable' \
147
+ unless tax_order.respond_to?(:to_sym)
148
+ raise ArgumentError, "#{tax_order} is not a valid taxonomic order" \
149
+ unless map.keys.include?(tax_order.to_sym)
150
+
151
+ the_order = translate('faker.creature.bird.order_common_map')[tax_order.to_sym]
152
+ sample(the_order).downcase
153
+ end
154
+ end
155
+
156
+ ##
157
+ # Produces a random and plausible common name for a bird
158
+ #
159
+ # @return [String]
160
+ #
161
+ # @example
162
+ # Faker::Creature::Bird.plausible_common_name #=> 'Hellinger's Wren'
163
+ #
164
+ # @faker.version next
165
+ def plausible_common_name
166
+ parse('creature.bird.plausible_common_names').capitalize
167
+ end
168
+
169
+ ##
170
+ # Produces a random and IMplausible common name for a bird
171
+ #
172
+ # @return [String]
173
+ #
174
+ # @example
175
+ # Faker::Creature::Bird.implausible_common_name #=> 'Hellinger's Cantankerous Chickadee'
176
+ #
177
+ # @faker.version next
178
+ def implausible_common_name
179
+ parse('creature.bird.implausible_common_names').capitalize
180
+ end
181
+
182
+ ##
183
+ # Produces a hash entry with a random order and a random common name
184
+ # that is of that order
185
+ #
186
+ # @return [Hash<order,common_name>]
187
+ #
188
+ # @example
189
+ # Faker::Creature::Bird.order_with_common_name #=> {
190
+ # order: ''Accipitriformes',
191
+ # common_name: 'Osprey'
192
+ # }
193
+ #
194
+ # @faker.version next
195
+ def order_with_common_name(tax_order = nil)
196
+ map = I18n.translate('faker.creature.bird.order_common_map')
197
+ o = tax_order.nil? ? order : tax_order
198
+ { order: o, common_name: sample(map[o.to_sym]) }
199
+ end
200
+ end
201
+ end
202
+ end
203
+ end
@@ -61,7 +61,7 @@ module Faker
61
61
  case base
62
62
  when 8 then generate_base8_ean
63
63
  when 13 then generate_base13_ean
64
- else raise ArgumentError, 'base must be 3 or 13'
64
+ else raise ArgumentError, 'base must be 8 or 13'
65
65
  end
66
66
  end
67
67
 
@@ -126,6 +126,34 @@ module Faker
126
126
  price
127
127
  end
128
128
 
129
+ ##
130
+ # Produces a randomized string of a brand name
131
+ # @example
132
+ # Faker::Commerce.brand #=> 'Apple'
133
+ #
134
+ # @return [string]
135
+ #
136
+ # @faker.version next
137
+ #
138
+ ##
139
+ def brand
140
+ fetch('commerce.brand')
141
+ end
142
+
143
+ ##
144
+ # Produces a randomized string of a vendor name
145
+ # @example
146
+ # Faker::Commerce.vendor #=> 'Dollar General'
147
+ #
148
+ # @return [string]
149
+ #
150
+ # @faker.version next
151
+ #
152
+ ##
153
+ def vendor
154
+ fetch('commerce.vendor')
155
+ end
156
+
129
157
  private
130
158
 
131
159
  def categories(num)
@@ -334,7 +334,7 @@ module Faker
334
334
  #
335
335
  # @faker.version 1.9.2
336
336
  def south_african_pty_ltd_registration_number
337
- regexify(/\d{4}\/\d{4,10}\/07/)
337
+ regexify(%r{\d{4}/\d{4,10}/07})
338
338
  end
339
339
 
340
340
  ##
@@ -347,7 +347,7 @@ module Faker
347
347
  #
348
348
  # @faker.version 1.9.2
349
349
  def south_african_close_corporation_registration_number
350
- regexify(/(CK\d{2}|\d{4})\/\d{4,10}\/23/)
350
+ regexify(%r{(CK\d{2}|\d{4})/\d{4,10}/23})
351
351
  end
352
352
 
353
353
  ##
@@ -360,7 +360,7 @@ module Faker
360
360
  #
361
361
  # @faker.version 1.9.2
362
362
  def south_african_listed_company_registration_number
363
- regexify(/\d{4}\/\d{4,10}\/06/)
363
+ regexify(%r{\d{4}/\d{4,10}/06})
364
364
  end
365
365
 
366
366
  ##
@@ -373,7 +373,7 @@ module Faker
373
373
  #
374
374
  # @faker.version 1.9.2
375
375
  def south_african_trust_registration_number
376
- regexify(/IT\d{2,4}\/\d{2,10}/)
376
+ regexify(%r{IT\d{2,4}/\d{2,10}})
377
377
  end
378
378
 
379
379
  ##
@@ -511,7 +511,6 @@ module Faker
511
511
  sum
512
512
  end
513
513
 
514
- # rubocop:disable Style/AsciiComments
515
514
  #
516
515
  # For more on Russian tax number algorithm here:
517
516
  # https://ru.wikipedia.org/wiki/Идентификационный_номер_налогоплательщика#Вычисление_контрольных_цифр
@@ -526,7 +525,6 @@ module Faker
526
525
  # Faker::Comnpany.russian_tax_number
527
526
  # Faker::Comnpany.russian_tax_number(region: 'AZ')
528
527
  # Faker::Comnpany.russian_tax_number(region: 'AZ', type: false)
529
- # rubocop:enable Style/AsciiComments
530
528
  def inn_number(region, type)
531
529
  n10 = [2, 4, 10, 3, 5, 9, 4, 6, 8]
532
530
  n11 = [7, 2, 4, 10, 3, 5, 9, 4, 6, 8]
@@ -553,7 +551,7 @@ module Faker
553
551
  end
554
552
 
555
553
  def spanish_cif_control_digit(organization_type, code)
556
- letters = %w[J A B C D E F G H]
554
+ letters = %w[J A B C D E F G H I]
557
555
 
558
556
  control = code.split('').each_with_index.inject(0) do |sum, (value, index)|
559
557
  if (index + 1).even?
@@ -43,6 +43,19 @@ module Faker
43
43
  def sha256
44
44
  OpenSSL::Digest::SHA256.hexdigest(Lorem.characters)
45
45
  end
46
+
47
+ ##
48
+ # Produces a SHA512 hash.
49
+ #
50
+ # @return [String]
51
+ #
52
+ # @example
53
+ # Faker::Crypto.sha512 #=> "7b9fc82a6642874833d01b74a7b4fae3d15373193b55cfba47327f8f0afdc8d0ea155b58639a03a887009ef997dab8dd8d36767620d430f6e787e5996e26da80"
54
+ #
55
+ # @faker.version next
56
+ def sha512
57
+ OpenSSL::Digest::SHA512.hexdigest(Lorem.characters)
58
+ end
46
59
  end
47
60
  end
48
61
  end
@@ -0,0 +1,33 @@
1
+ # frozen_string_literal: true
2
+
3
+ module Faker
4
+ class Emotion < Base
5
+ class << self
6
+ ##
7
+ # Produces an emotion noun.
8
+ #
9
+ # @return [String]
10
+ #
11
+ # @example
12
+ # Faker::Emotion.noun #=> "amazement"
13
+ #
14
+ # @faker.version next
15
+ def noun
16
+ fetch('emotion.noun')
17
+ end
18
+
19
+ ##
20
+ # Produces an emotion adjective.
21
+ #
22
+ # @return [String]
23
+ #
24
+ # @example
25
+ # Faker::Emotion.adjective # => "nonplussed"
26
+ #
27
+ # @faker.version next
28
+ def adjective
29
+ fetch('emotion.adjective')
30
+ end
31
+ end
32
+ end
33
+ end
@@ -84,6 +84,19 @@ module Faker
84
84
  rescue I18n::MissingTranslationData
85
85
  raise ArgumentError, "Could not find market named #{market}"
86
86
  end
87
+
88
+ ##
89
+ # Returns a randomly-selected stock market.
90
+ #
91
+ # @return [String]
92
+ #
93
+ # @example
94
+ # Faker::Finance.stock_market #=> 'NASDAQ'
95
+ #
96
+ # @faker.version next
97
+ def stock_market
98
+ fetch('finance.stock_market')
99
+ end
87
100
  end
88
101
  end
89
102
  end