faker 1.6.5 → 1.6.6

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 778f79b3ecce3e5b10dff76634ffc082c2e4ce17
4
- data.tar.gz: 0cbeb94d6ea09fb529354d3eadc4ddfbf0492310
3
+ metadata.gz: 1b02bc9f1302ebe14e607d307e57cb5e48b8a6fb
4
+ data.tar.gz: 782b7c8f5abfb90e05379c90526d0f2ad2bd97b4
5
5
  SHA512:
6
- metadata.gz: 7a21ca0764a52bbf3b632032b3c557e01e2f1184e1aa9de336ab8914350c4adb5de7fb57621db2e7d69355c86713b74836e776cd41d9171a717cb51e227fbb58
7
- data.tar.gz: 5f12b680115096a7b8d0363aeaa7b040a005177d30c27f93f6e3bc8787189d6df49935fd61f735aec03dce6367fb5ecdaea35b849fb42cb2fc832ebc781e7967
6
+ metadata.gz: 1aaadc4bb22e1b81ed0473cb8037a006c0d008c2ff91bb56d31e8c46bce4ae600c8dc8a69b48a97a558a1782b221d20f14cd80aba8029b0b61660cf76256d166
7
+ data.tar.gz: 89f6ef69397402c66816241070300ee480186863ac491d4a243b9166163223157efcd651902adf5cdeef9c92bdbd2c71ddf3292bc6f8c19dcaef87daed2b1416
@@ -1,3 +1,7 @@
1
+ == 1.6.6 2016-07-25
2
+ * Added Faker::GameOfThrones, Faker::Pokemon
3
+ * Fixes for Faker::Vehicle.vin, Faker::Hacker.say_something_smart
4
+
1
5
  == 1.6.5 2016-07-08
2
6
  * Removed Faker::ChuckNorris.name
3
7
 
data/README.md CHANGED
@@ -54,6 +54,8 @@ Contents
54
54
  - [Faker::Space](#fakerspace)
55
55
  - [Faker::Music](#fakermusic)
56
56
  - [Faker::Vehicle](#fakervehicle)
57
+ - [Faker::GameOfThrones](#fakergameofthrones)
58
+ - [Faker::Pokemon](#fakerpokemon)
57
59
  - [Customization](#customization)
58
60
  - [Contributing](#contributing)
59
61
  - [Contact](#contact)
@@ -840,6 +842,26 @@ Faker::Vehicle.vin #=> "LLDWXZLG77VK2LUUF"
840
842
  Faker::Vehicle.manufacture #=> "JAGUAR CARS LTD"
841
843
  ```
842
844
 
845
+ ###Faker::GameOfThrones
846
+ ----------------
847
+
848
+ ```ruby
849
+ Faker::GameOfThrones.character #=> "Tyrion Lannister"
850
+
851
+ Faker::GameOfThrones.house #=> "Stark"
852
+
853
+ Faker::GameOfThrones.city #=> "Lannisport"
854
+ ```
855
+
856
+ ###Faker::Pokemon
857
+ ----------------
858
+
859
+ ```ruby
860
+ Faker::Pokemon.name #=> "Pikachu"
861
+
862
+ Faker::Pokemon.location #=> "Pallet Town"
863
+ ```
864
+
843
865
  Customization
844
866
  ------------
845
867
  Since you may want to make addresses and other types of data look different
@@ -227,6 +227,8 @@ require 'faker/space'
227
227
  require 'faker/yoda'
228
228
  require 'faker/music'
229
229
  require 'faker/vehicle'
230
+ require 'faker/game_of_thrones'
231
+ require 'faker/pokemon'
230
232
 
231
233
  require 'extensions/array'
232
234
  require 'extensions/symbol'
@@ -5,7 +5,7 @@ module Faker
5
5
  from = get_date_object(from)
6
6
  to = get_date_object(to)
7
7
 
8
- Faker::Base::rand_in_range(from, to)
8
+ Faker::Base.rand_in_range(from, to)
9
9
  end
10
10
 
11
11
  def between_except(from, to, excepted)
@@ -60,8 +60,8 @@ module Faker
60
60
 
61
61
  def customized_bound(bound, increase = false)
62
62
  if (bound % 4) != 0
63
- bound = bound + 1 if increase
64
- bound = bound - 1 unless increase
63
+ bound += 1 if increase
64
+ bound -= 1 unless increase
65
65
  customized_bound(bound, increase)
66
66
  else
67
67
  bound
@@ -0,0 +1,17 @@
1
+ module Faker
2
+ class GameOfThrones < Base
3
+ class << self
4
+ def character
5
+ fetch('game_of_thrones.characters')
6
+ end
7
+
8
+ def house
9
+ fetch('game_of_thrones.houses')
10
+ end
11
+
12
+ def city
13
+ fetch('game_of_thrones.cities')
14
+ end
15
+ end
16
+ end
17
+ end
@@ -2,18 +2,18 @@
2
2
  module Faker
3
3
  class Hacker < Base
4
4
  flexible :hacker
5
-
5
+
6
6
  class << self
7
7
  def say_something_smart
8
8
  phrases.sample
9
9
  end
10
-
10
+
11
11
  def abbreviation; fetch('hacker.abbreviation'); end
12
12
  def adjective; fetch('hacker.adjective'); end
13
13
  def noun; fetch('hacker.noun'); end
14
14
  def verb; fetch('hacker.verb'); end
15
15
  def ingverb; fetch('hacker.ingverb'); end
16
-
16
+
17
17
  def phrases
18
18
  [ "If we #{verb} the #{noun}, we can get to the #{abbreviation} #{noun} through the #{adjective} #{abbreviation} #{noun}!",
19
19
  "We need to #{verb} the #{adjective} #{abbreviation} #{noun}!",
@@ -21,8 +21,8 @@ module Faker
21
21
  "You can't #{verb} the #{noun} without #{ingverb} the #{adjective} #{abbreviation} #{noun}!",
22
22
  "Use the #{adjective} #{abbreviation} #{noun}, then you can #{verb} the #{adjective} #{noun}!",
23
23
  "The #{abbreviation} #{noun} is down, #{verb} the #{adjective} #{noun} so we can #{verb} the #{abbreviation} #{noun}!",
24
- "#{ingverb} the #{noun} won't do anything, we need to #{verb} the #{adjective} #{abbreviation} #{noun}!",
25
- "I'll #{verb} the #{adjective} #{abbreviation} #{noun}, that should #{noun} the #{abbreviation} #{noun}!"
24
+ "#{ingverb} the #{noun} won't do anything, we need to #{verb} the #{adjective} #{abbreviation} #{noun}!".capitalize,
25
+ "I'll #{verb} the #{adjective} #{abbreviation} #{noun}, that should #{noun} the #{abbreviation} #{noun}!"
26
26
  ]
27
27
  end
28
28
  end
@@ -0,0 +1,13 @@
1
+ module Faker
2
+ class Pokemon < Base
3
+ class << self
4
+ def name
5
+ fetch('pokemon.names')
6
+ end
7
+
8
+ def location
9
+ fetch('pokemon.locations')
10
+ end
11
+ end
12
+ end
13
+ end
@@ -1,3 +1,3 @@
1
1
  module Faker #:nodoc:
2
- VERSION = "1.6.5"
2
+ VERSION = "1.6.6"
3
3
  end
@@ -57,6 +57,13 @@ de:
57
57
  color:
58
58
  name: [rot, grün, blau, gelb, lila, weiß, schwarz, orange, rosa, grau, braun, violett, türkis, oliv, beige, ocker, sand, mocka, bordeaux, aprikose, mint-grün, magenta, gold, silber, bronze, limette, azur, pink]
59
59
 
60
+ commerce:
61
+ department: ["Bücher", "Filme", "Musik", "Spiele", "Elektronik", "Computer", "Zu Hause", "Garten", "Werkzeug", "Lebensmittel", "Gesundheit", "Schönheit", "Spiele", "Kinder", "Baby", "Kleider", "Schuhe", "Juwelen", "Sport", "Outdoor", "Auto", "Industrie"]
62
+ product_name:
63
+ adjective: [Kleine, Ergonomische, Rustikale, Intelligente, Wunderschöne, Unglaubliche, Fantastische, Praktische, Elegante, Tolle, Enorme, Mittelmäßige, Synergetische, Schwerlast, Leichte, Aerodynamische, Haltbare]
64
+ material: [Stahl, Holz, Beton, Plastik, Baumwoll, Granit, Gummi, Leder, Seiden, Wolle, Leinen, Marmor, Eisen, Bronze, Kupfer, Aluminium, Papier]
65
+ product: [Stühle, Autos, Computer, Handschue, Hosen, Hemden, Tische, Schuhe, Hüte, Teller, Messer, Flaschen, Jacke, Lampe, Tastatur, Tasche, Bank, Uhr, Armbanduhr, Geldbörse]
66
+
60
67
  phone_number:
61
68
  formats: ['(0###) #########', '(0####) #######', '+49-###-#######', '+49-####-########']
62
69
 
@@ -266,23 +266,23 @@ en:
266
266
  instruments: ['Electric Guitar', 'Acoustic Guitar', 'Flute', 'Trumpet', 'Clarinet', 'Cello', 'Harp', 'Xylophone', 'Harmonica', 'Accordion', 'Organ', 'Piano', 'Ukelele', 'Saxophone', 'Drums', 'Violin', 'Bass Guitar']
267
267
 
268
268
  vehicle:
269
- year: [A, L, Y, B, M, 1, C, N, 2, D, P, 3, E, R, 4, F, S, 5, G, T, 6, H, V, 7, J, W, 8, K, X, 9]
269
+ year: [A, L, Y, B, M, '1', C, N, '2', D, P, '3', E, R, '4', F, S, '5', G, T, '6', H, V, '7', J, W, '8', K, X, '9']
270
270
  manufacture:
271
271
  - name: MARQUESS ELECTRIC CAR COMPANY
272
272
  wmi: 15E
273
273
  wmi_ext:
274
274
  - name: AJAX MANUFACTURING COMPANY, INC.
275
275
  wmi: 1A9
276
- wmi_ext: 396
276
+ wmi_ext: '396'
277
277
  - name: DAIMLERCHRYSLER CORPORATION
278
278
  wmi: 1B6
279
279
  wmi_ext:
280
280
  - name: BAY EQUIPMENT & REPAIR
281
281
  wmi: 1B9
282
- wmi_ext: 290
282
+ wmi_ext: '290'
283
283
  - name: CHOPPER GUY'S, INC.
284
284
  wmi: 1C9
285
- wmi_ext: 564
285
+ wmi_ext: '564'
286
286
  - name: COMMERCIAL MOBILE SYSTEMS
287
287
  wmi: 1C9
288
288
  wmi_ext: ACA
@@ -294,16 +294,16 @@ en:
294
294
  wmi_ext:
295
295
  - name: FMC CORP
296
296
  wmi: 1F9
297
- wmi_ext: 041
297
+ wmi_ext: '041'
298
298
  - name: GENERAL MOTORS CORPORATION
299
299
  wmi: 1G8
300
300
  wmi_ext:
301
301
  - name: AUTOMOTRIZ PEYCHA, S.A. DE C.V.
302
302
  wmi: 3A9
303
- wmi_ext: 068
303
+ wmi_ext: '068'
304
304
  - name: REGIOBUS, S.A. DE C.V.
305
305
  wmi: 3R9
306
- wmi_ext: 097
306
+ wmi_ext: '097'
307
307
  - name: Interstate West Corporation
308
308
  wmi: 4RA
309
309
  wmi_ext:
@@ -413,3 +413,11 @@ en:
413
413
  file:
414
414
  extension: ["flac", "mp3", "wav", "bmp", "gif", "jpeg", "jpg", "png", "tiff", "css", "csv", "html", "js", "json", "txt", "mp4", "avi", "mov", "webm", "doc", "docx", "xls", "xlsx", "ppt", "pptx", "odt", "ods", "odp", "pages", "numbers", "key", "pdf"]
415
415
  mime_type: ["application/atom+xml", "application/ecmascript", "application/EDI-X12", "application/EDIFACT", "application/json", "application/javascript", "application/ogg", "application/pdf", "application/postscript", "application/rdf+xml", "application/rss+xml", "application/soap+xml", "application/font-woff", "application/xhtml+xml", "application/xml-dtd", "application/xop+xml", "application/zip", "application/gzip", "audio/basic", "audio/L24", "audio/mp4", "audio/mpeg", "audio/ogg", "audio/vorbis", "audio/vnd.rn-realaudio", "audio/vnd.wave", "audio/webm", "image/gif", "image/jpeg", "image/pjpeg", "image/png", "image/svg+xml", "image/tiff", "image/vnd.microsoft.icon", "message/http", "message/imdn+xml", "message/partial", "message/rfc822", "model/example", "model/iges", "model/mesh", "model/vrml", "model/x3d+binary", "model/x3d+vrml", "model/x3d+xml", "multipart/mixed", "multipart/alternative", "multipart/related", "multipart/form-data", "multipart/signed", "multipart/encrypted", "text/cmd", "text/css", "text/csv", "text/html", "text/javascript", "text/plain", "text/vcard", "text/xml", "video/mpeg", "video/mp4", "video/ogg", "video/quicktime", "video/webm", "video/x-matroska", "video/x-ms-wmv", "video/x-flv"]
416
+
417
+ game_of_thrones:
418
+ characters: ['Daenerys Targaryen', 'Jon Snow', 'Arya Stark', 'Gregor Clegane', 'Melisandre', 'Tyrion Lannister', 'Jaime Lannister', 'Cersei Lannister', 'Petyr Baelish', 'Jorah Mormont', 'Sansa Stark', 'Theon Greyjoy', 'Bran Stark', 'Sandor Clegane', 'Joffrey Baratheon', 'Catelyn Stark', 'Robb Stark', 'Ned Stark', 'Robert Baratheon', 'Viserys Targaryen', 'Varys', 'Samwell Tarly', 'Bronn', 'Tywin Lannister', 'Jeor Mormont', 'Shae', 'Gendry', 'Tommen Baratheon', "Jaqen H'ghar", 'Khal Drogo', 'Davos Seaworth', 'Margaery Tyrell', 'Stannis Baratheon', 'Ygritte', 'Brienne of Tarth', 'Roose Bolton', 'Ramsay Bolton']
419
+ houses: ['Arryn', 'Baratheon', 'Bolton', 'Frey', 'Greyjoy', 'Lannister', 'Martell', 'Stark', 'Targaryen', 'Tully', 'Tyrell']
420
+ cities: ['Braavos', "King's Landing", 'Volantis', 'Qarth', 'Asshai', 'Old Valyria', 'Meereen', 'Oldtown', 'Pentos', 'Astapor', 'Yunkai', 'Lorath', 'Lys', 'Vaes Dothrak', 'Sunspear', 'White Harbor', 'Myr', 'Lannisport', 'Qohor', 'Tyrosh', 'Norvos', 'Gulltown', 'Old Ghis', 'New Ghis', 'Mantarys', 'Bayasabhad', 'Elyria', 'Tolos', 'Samyrian', 'Chroyane', 'Tyria', 'Oros', 'Bhorash', 'Ny Sar', 'Sar Meel', 'Ar Noy']
421
+ pokemon:
422
+ names: ["Bulbasaur", "Ivysaur", "Venusaur", "Charmander", "Charmeleon", "Charizard", "Squirtle", "Wartortle", "Blastoise", "Caterpie", "Metapod", "Butterfree", "Weedle", "Kakuna", "Beedrill", "Pidgey", "Pidgeotto", "Pidgeot", "Rattata", "Raticate", "Spearow", "Fearow", "Ekans", "Arbok", "Pikachu", "Raichu", "Sandshrew", "Sandslash", "Nidoran", "Nidorina", "Nidoqueen", "Nidoran", "Nidorino", "Nidoking", "Clefairy", "Clefable", "Vulpix", "Ninetales", "Jigglypuff", "Wigglytuff", "Zubat", "Golbat", "Oddish", "Gloom", "Vileplume", "Paras", "Parasect", "Venonat", "Venomoth", "Diglett", "Dugtrio", "Meowth", "Persian", "Psyduck", "Golduck", "Mankey", "Primeape", "Growlithe", "Arcanine", "Poliwag", "Poliwhirl", "Poliwrath", "Abra", "Kadabra", "Alakazam", "Machop", "Machoke", "Machamp", "Bellsprout", "Weepinbell", "Victreebel", "Tentacool", "Tentacruel", "Geodude", "Graveler", "Golem", "Ponyta", "Rapidash", "Slowpoke", "Slowbro", "Magnemite", "Magneton", "Farfetch'd", "Doduo", "Dodrio", "Seel", "Dewgong", "Grimer", "Muk", "Shellder", "Cloyster", "Gastly", "Haunter", "Gengar", "Onix", "Drowzee", "Hypno", "Krabby", "Kingler", "Voltorb", "Electrode", "Exeggcute", "Exeggutor", "Cubone", "Marowak", "Hitmonlee", "Hitmonchan", "Lickitung", "Koffing", "Weezing", "Rhyhorn", "Rhydon", "Chansey", "Tangela", "Kangaskhan", "Horsea", "Seadra", "Goldeen", "Seaking", "Staryu", "Starmie", "Mr.", "Scyther", "Jynx", "Electabuzz", "Magmar", "Pinsir", "Tauros", "Magikarp", "Gyarados", "Lapras", "Ditto", "Eevee", "Vaporeon", "Jolteon", "Flareon", "Porygon", "Omanyte", "Omastar", "Kabuto", "Kabutops", "Aerodactyl", "Snorlax", "Articuno", "Zapdos", "Moltres", "Dratini", "Dragonair", "Dragonite", "Mewtwo"]
423
+ locations: ["Accumula Town", "Ambrette Town", "Anistar City", "Anville Town", "Aquacorde Town", "Aspertia City", "Azalea Town", "Black City", "Blackthorn City", "Camphrier Town", "Canalave City", "Castelia City", "Celadon City", "Celestic Town", "Cerulean City", "Cherrygrove City", "Cianwood City", "Cinnabar Island", nil, "Coumarine City", "Couriway Town", "Cyllage City", "Dendemille Town", "Dewford Town", "Driftveil City", "Ecruteak City", "Eterna City", "Ever Grande City", "Fallarbor Town", "Fight Area", "Five Island", "Floaroma Town", "Floccesy Town", "Fortree City", "Four Island", "Frontier Access", "Fuchsia City", "Geosenge Town", "Goldenrod City", "Hearthome City", "Humilau City", "Icirrus City", "Jubilife City", "Kiloude City", "Lacunosa Town", "Lavaridge Town", "Lavender Town", "Laverre City", "Lentimas Town", "Littleroot Town", "Lilycove City", "Lumiose City", "Mahogany Town", "Mauville City", "Mistralton City", "Mossdeep City", "Nacrene City", "New Bark Town", "Nimbasa City", "Nuvema Town", "Oldale Town", "Olivine City", "One Island", "Opelucid City", "Oreburgh City", "Pacifidlog Town", "Pallet Town", "Pastoria City", "Petalburg City", "Pewter City", "Resort Area", "Rustboro City", "Safari Zone Gate", "Saffron City", "Sandgem Town", "Santalune City", "Striaton City", "Seven Island", "Shalour City", "Six Island", "Slateport City", "Snowbelle City", "Snowpoint City", "Solaceon Town", "Sootopolis City", "Sunyshore City", "Survival Area", "Three Island", "Twinleaf Town", "Two Island", "Undella Town", "Vaniville Town", "Veilstone City", "Verdanturf Town", "Vermilion City", "Violet City", "Virbank City", "Viridian City", "White Forest"]
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: faker
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.5
4
+ version: 1.6.6
5
5
  platform: ruby
6
6
  authors:
7
7
  - Benjamin Curtis
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-07-08 00:00:00.000000000 Z
11
+ date: 2016-07-25 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: i18n
@@ -57,6 +57,7 @@ files:
57
57
  - lib/faker/educator.rb
58
58
  - lib/faker/file.rb
59
59
  - lib/faker/finance.rb
60
+ - lib/faker/game_of_thrones.rb
60
61
  - lib/faker/hacker.rb
61
62
  - lib/faker/hipster.rb
62
63
  - lib/faker/id_number.rb
@@ -67,6 +68,7 @@ files:
67
68
  - lib/faker/number.rb
68
69
  - lib/faker/phone_number.rb
69
70
  - lib/faker/placeholdit.rb
71
+ - lib/faker/pokemon.rb
70
72
  - lib/faker/shakespeare.rb
71
73
  - lib/faker/slack_emoji.rb
72
74
  - lib/faker/space.rb