From b74c4c0793a33a6580e124be7e2b01f88b9fe3a5 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 17:54:12 -0600 Subject: [PATCH 01/14] Add YARD docs for Faker::Nation. --- lib/faker/default/nation.rb | 50 +++++++++++++++++++++++++++++++++---- 1 file changed, 45 insertions(+), 5 deletions(-) diff --git a/lib/faker/default/nation.rb b/lib/faker/default/nation.rb index f759f2ef59..5e8156242f 100644 --- a/lib/faker/default/nation.rb +++ b/lib/faker/default/nation.rb @@ -4,27 +4,67 @@ module Faker class Nation < Base flexible :nation class << self - # Fetch random nationality + ## + # Produces a random nationality. + # + # @return [String] + # + # @example + # Faker::Nation.nationality #=> "Nepalese" + # + # @faker.version 1.9.0 def nationality fetch('nation.nationality') end - # Fetch random national flag emoji + ## + # Produces a random national flag emoji. + # + # @return [String] + # + # @example + # Faker::Nation.flag #=> "🇫🇮" + # + # @faker.version 1.9.0 def flag sample(translate('faker.nation.flag')).pack('C*').force_encoding('utf-8') end - # Fetch random language + ## + # Produces a random national language. + # + # @return [String] + # + # @example + # Faker::Nation.language #=> "Nepali" + # + # @faker.version 1.9.0 def language fetch('nation.language') end - # Fetch random capital city + ## + # Produces a random capital city. + # + # @return [String] + # + # @example + # Faker::Nation.capital_city #=> "Kathmandu" + # + # @faker.version 1.9.0 def capital_city fetch('nation.capital_city') end - # Fetch random natinal sport + ## + # Produces a random national sport. + # + # @return [String] + # + # @example + # Faker::Nation.national_sport #=> "dandi biyo" + # + # @faker.version 1.9.0 def national_sport fetch('team.sport') end From ffec8114434507ee8b839a297443d8aacc9587cc Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:30:37 -0600 Subject: [PATCH 02/14] Add YARD docs for One Piece. --- lib/faker/japanese_media/one_piece.rb | 48 +++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/lib/faker/japanese_media/one_piece.rb b/lib/faker/japanese_media/one_piece.rb index b0923ceb84..4a38245d2e 100644 --- a/lib/faker/japanese_media/one_piece.rb +++ b/lib/faker/japanese_media/one_piece.rb @@ -4,26 +4,74 @@ module Faker class JapaneseMedia class OnePiece < Base class << self + # Produces a character from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.character #=> "Monkey D. Luffy" + # + # @faker.version 1.8.5 def character fetch('one_piece.characters') end + # Produces a sea from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.sea #=> "East Blue" + # + # @faker.version 1.8.5 def sea fetch('one_piece.seas') end + # Produces an island from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.island #=> "Laftel" + # + # @faker.version 1.8.5 def island fetch('one_piece.islands') end + # Produces a location from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.location #=> "Foosha Village" + # + # @faker.version 1.8.5 def location fetch('one_piece.locations') end + # Produces a quote from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.quote #=> "ONE PIECE IS REAL!" + # + # @faker.version 1.8.5 def quote fetch('one_piece.quotes') end + # Produces an akuma no mi from One Piece. + # + # @return [String] + # + # @example + # Faker::JapaneseMedia::OnePiece.akuma_no_mi #=> "Gomu Gomu no Mi" + # + # @faker.version 1.8.5 def akuma_no_mi fetch('one_piece.akumas_no_mi') end From 6e0fa9349a91dd88f415762d96ade6c398110032 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:41:12 -0600 Subject: [PATCH 03/14] Add YARD docs for The Big Lebowski. --- lib/faker/movies/lebowski.rb | 24 ++++++++++++++++++++++++ 1 file changed, 24 insertions(+) diff --git a/lib/faker/movies/lebowski.rb b/lib/faker/movies/lebowski.rb index 68b92dc4ee..c8494ad5d7 100644 --- a/lib/faker/movies/lebowski.rb +++ b/lib/faker/movies/lebowski.rb @@ -4,14 +4,38 @@ module Faker class Movies class Lebowski < Base class << self + # Produces an actor from The Big Lebowski. + # + # @return [String] + # + # @example + # Faker::Movies::Lebowski.actor #=> "John Goodman" + # + # @faker.version 1.8.8 def actor fetch('lebowski.actors') end + # Produces a character from The Big Lebowski. + # + # @return [String] + # + # @example + # Faker::Movies::Lebowski.character #=> "Jackie Treehorn" + # + # @faker.version 1.8.8 def character fetch('lebowski.characters') end + # Produces a quote from The Big Lebowski. + # + # @return [String] + # + # @example + # Faker::Movies::Lebowski.quote #=> "Forget it, Donny, you're out of your element!" + # + # @faker.version 1.8.8 def quote fetch('lebowski.quotes') end From 009c2f292ba8d3c0aa57bca253910a908e389050 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:47:17 -0600 Subject: [PATCH 04/14] Add YARD docs for Star Wars. --- lib/faker/movies/star_wars.rb | 85 +++++++++++++++++++++++++++++++++++ 1 file changed, 85 insertions(+) diff --git a/lib/faker/movies/star_wars.rb b/lib/faker/movies/star_wars.rb index ad34bf8b7e..6935d41640 100644 --- a/lib/faker/movies/star_wars.rb +++ b/lib/faker/movies/star_wars.rb @@ -4,38 +4,110 @@ module Faker class Movies class StarWars < Base class << self + # Produces a call squadron from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.call_squadron #=> "Green" + # + # @faker.version 1.6.2 def call_squadron sample(call_squadrons) end + # Produces a call sign from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.call_sign #=> "Grey 5" + # + # @faker.version 1.6.2 def call_sign numerify(parse('star_wars.call_sign')) end + # Produces a call number from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.call_number #=> "Leader" + # + # @faker.version 1.6.2 def call_number sample(call_numbers) end + # Produces a character from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.character #=> "Anakin Skywalker" + # + # @faker.version 1.6.2 def character sample(characters) end + # Produces a droid from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.droid #=> "C-3PO" + # + # @faker.version 1.6.2 def droid sample(droids) end + # Produces a planet from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.planet #=> "Tatooine" + # + # @faker.version 1.6.2 def planet sample(planets) end + # Produces a species from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.specie #=> "Gungan" + # + # @faker.version 1.6.2 def specie sample(species) end + # Produces a vehicle from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.vehicle #=> "Sandcrawler" + # + # @faker.version 1.6.2 def vehicle sample(vehicles) end + # Produces a wookiee sentence from Star Wars. + # + # @return [String] + # + # @example + # Faker::Movies::StarWars.wookiee_sentence #=> "Yrroonn ru ooma roo ahuma ur roooarrgh hnn-rowr." + # + # @faker.version 1.6.2 def wookiee_sentence sentence = sample(wookiee_words).capitalize @@ -44,6 +116,19 @@ def wookiee_sentence sentence + sample(['.', '?', '!']) end + # Produces a quote from Star Wars. + # + # @param character [String] The name of a character to derive a quote from. + # @return [String] + # + # @example + # Faker::Movies::StarWars.quote #=> "Aren't you a little short for a Stormtrooper?" + # + # @example + # Faker::Movies::StarWars.quote(character: "leia_organa") + # #=> "Aren’t you a little short for a Stormtrooper?" + # + # @faker.version 1.6.2 def quote(legacy_character = NOT_GIVEN, character: nil) warn_for_deprecated_arguments do |keywords| keywords << :character if legacy_character != NOT_GIVEN From 14b6850a10245a3326496c31b58ed9d09b460c39 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:50:14 -0600 Subject: [PATCH 05/14] Add YARD docs for HarryPotter. --- lib/faker/movies/harry_potter.rb | 48 ++++++++++++++++++++++++++++++++ 1 file changed, 48 insertions(+) diff --git a/lib/faker/movies/harry_potter.rb b/lib/faker/movies/harry_potter.rb index 62d6e20830..51563934d3 100644 --- a/lib/faker/movies/harry_potter.rb +++ b/lib/faker/movies/harry_potter.rb @@ -4,26 +4,74 @@ module Faker class Movies class HarryPotter < Base class << self + # Produces a character from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.character #=> "Harry Potter" + # + # @faker.version 1.7.3 def character fetch('harry_potter.characters') end + # Produces a location from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.location #=> "Hogwarts" + # + # @faker.version 1.7.3 def location fetch('harry_potter.locations') end + # Produces a quote from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.quote #=> "I solemnly swear that I am up to good." + # + # @faker.version 1.7.3 def quote fetch('harry_potter.quotes') end + # Produces a book from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.book #=> "Harry Potter and the Chamber of Secrets" + # + # @faker.version 1.7.3 def book fetch('harry_potter.books') end + # Produces a house from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.house #=> "Gryffindor" + # + # @faker.version 1.7.3 def house fetch('harry_potter.houses') end + # Produces a spell from Harry Potter. + # + # @return [String] + # + # @example + # Faker::Movies::HarryPotter.spell #=> "Reparo" + # + # @faker.version 1.7.3 def spell fetch('harry_potter.spells') end From eaba395641bffaf13377318c024f7c7fdc7e8b2f Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:53:38 -0600 Subject: [PATCH 06/14] Add YARD docs for Back to the Future. --- lib/faker/movies/back_to_the_future.rb | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/lib/faker/movies/back_to_the_future.rb b/lib/faker/movies/back_to_the_future.rb index 040feb48eb..35c89614a1 100644 --- a/lib/faker/movies/back_to_the_future.rb +++ b/lib/faker/movies/back_to_the_future.rb @@ -4,14 +4,39 @@ module Faker class Movies class BackToTheFuture < Base class << self + # Produces a character from Back to the Future. + # + # @return [String] + # + # @example + # Faker::Movies::BackToTheFuture.character #=> "Marty McFly" + # + # @faker.version 1.8.5 def character fetch('back_to_the_future.characters') end + # Produces a date from Back to the Future. + # + # @return [String] + # + # @example + # Faker::Movies::BackToTheFuture.date #=> "November 5, 1955" + # + # @faker.version 1.8.5 def date fetch('back_to_the_future.dates') end + # Produces a quote from Back to the Future. + # + # @return [String] + # + # @example + # Faker::Movies::BackToTheFuture.quote + # #=> "Roads? Where we're going, we don't need roads." + # + # @faker.version 1.8.5 def quote fetch('back_to_the_future.quotes') end From 05b462419820fd68b0a7b7d8e86c2a4b432176ac Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:57:14 -0600 Subject: [PATCH 07/14] Add YARD docs for Ghostbusters. --- lib/faker/movies/ghostbusters.rb | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/lib/faker/movies/ghostbusters.rb b/lib/faker/movies/ghostbusters.rb index b1a1e4d9aa..df3479253c 100644 --- a/lib/faker/movies/ghostbusters.rb +++ b/lib/faker/movies/ghostbusters.rb @@ -4,14 +4,39 @@ module Faker class Movies class Ghostbusters < Base class << self + # Produces an actor from Ghostbusters. + # + # @return [String] + # + # @example + # Faker::Movies::Ghostbusters.actor #=> "Bill Murray" + # + # @faker.version 1.9.2 def actor fetch('ghostbusters.actors') end + # Produces a character from Ghostbusters. + # + # @return [String] + # + # @example + # Faker::Movies::Ghostbusters.character #=> "Dr. Egon Spengler" + # + # @faker.version 1.9.2 def character fetch('ghostbusters.characters') end + # Produces a quote from Ghostbusters. + # + # @return [String] + # + # @example + # Faker::Movies::Ghostbusters.quote + # #=> "I tried to think of the most harmless thing. Something I loved from my childhood. Something that could never ever possibly destroy us. Mr. Stay Puft!" + # + # @faker.version 1.9.2 def quote fetch('ghostbusters.quotes') end From 8ad841c567e44f65cf95b664df77d8f21e272d84 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 19:58:49 -0600 Subject: [PATCH 08/14] Add YARD docs for Lord of the Rings. --- lib/faker/movies/lord_of_the_rings.rb | 25 +++++++++++++++++++++++++ 1 file changed, 25 insertions(+) diff --git a/lib/faker/movies/lord_of_the_rings.rb b/lib/faker/movies/lord_of_the_rings.rb index b737ac7001..1205bdb719 100644 --- a/lib/faker/movies/lord_of_the_rings.rb +++ b/lib/faker/movies/lord_of_the_rings.rb @@ -4,14 +4,39 @@ module Faker class Movies class LordOfTheRings < Base class << self + # Produces a character from Lord of the Rings. + # + # @return [String] + # + # @example + # Faker::Movies::LordOfTheRings.character #=> "Legolas" + # + # @faker.version 1.7.0 def character fetch('lord_of_the_rings.characters') end + # Produces a location from Lord of the Rings. + # + # @return [String] + # + # @example + # Faker::Movies::LordOfTheRings.location #=> "Helm's Deep" + # + # @faker.version 1.7.0 def location fetch('lord_of_the_rings.locations') end + # Produces a quote from Lord of the Rings. + # + # @return [String] + # + # @example + # Faker::Movies::LordOfTheRings.quote + # #=> "I wish the Ring had never come to me. I wish none of this had happened." + # + # @faker.version 1.9.0 def quote fetch('lord_of_the_rings.quotes') end From a0ee3822510061806a98d503ba1511f7644f6300 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:00:38 -0600 Subject: [PATCH 09/14] Add YARD docs for The Princess Bride. --- lib/faker/movies/princess_bride.rb | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/lib/faker/movies/princess_bride.rb b/lib/faker/movies/princess_bride.rb index 3484d108dc..f96fa9ba96 100644 --- a/lib/faker/movies/princess_bride.rb +++ b/lib/faker/movies/princess_bride.rb @@ -4,10 +4,27 @@ module Faker class Movies class PrincessBride < Base class << self + # Produces a character from The Princess Bride. + # + # @return [String] + # + # @example + # Faker::Movies::PrincessBride.character #=> "Dread Pirate Roberts" + # + # @faker.version 1.9.0 def character fetch('princess_bride.characters') end + # Produces a quote from The Princess Bride. + # + # @return [String] + # + # @example + # Faker::Movies::PrincessBride.quote + # #=> "Hello. My name is Inigo Montoya. You killed my father. Prepare to die!" + # + # @faker.version 1.9.0 def quote fetch('princess_bride.quotes') end From 8cb1095d5349ed9256939dcfa0d86931cd212eaa Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:04:05 -0600 Subject: [PATCH 10/14] Add YARD docs for V For Vendetta. --- lib/faker/movies/v_for_vendetta.rb | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/lib/faker/movies/v_for_vendetta.rb b/lib/faker/movies/v_for_vendetta.rb index 85a87ead93..e66dbb16e6 100644 --- a/lib/faker/movies/v_for_vendetta.rb +++ b/lib/faker/movies/v_for_vendetta.rb @@ -4,14 +4,40 @@ module Faker class Movies class VForVendetta < Base class << self + # Produces a character from V For Vendetta. + # + # @return [String] + # + # @example + # Faker::Movies::VForVendetta.character #=> "V" + # + # @faker.version 1.8.5 def character fetch('v_for_vendetta.characters') end + # Produces a speech from V For Vendetta. + # + # @return [String] + # + # @example + # Faker::Movies::VForVendetta.speech + # #=> "Remember, remember, the Fifth of November, the Gunpowder Treason and Plot. I know of no reason why the Gunpowder Treason should ever be forgot..." + # + # @faker.version 1.8.5 def speech fetch('v_for_vendetta.speeches') end + # Produces a quote from V For Vendetta. + # + # @return [String] + # + # @example + # Faker::Movies::VForVendetta.quote + # #=> "People should not be afraid of their governments. Governments should be afraid of their people." + # + # @faker.version 1.8.5 def quote fetch('v_for_vendetta.quotes') end From c975a75859fd59bac5f171556bfcab2fc14ba479 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:05:29 -0600 Subject: [PATCH 11/14] Fixes to appease rubocop. --- lib/faker/default/nation.rb | 3 +++ lib/faker/japanese_media/one_piece.rb | 2 +- lib/faker/movies/star_wars.rb | 2 +- 3 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/faker/default/nation.rb b/lib/faker/default/nation.rb index 5e8156242f..2114269889 100644 --- a/lib/faker/default/nation.rb +++ b/lib/faker/default/nation.rb @@ -17,6 +17,8 @@ def nationality fetch('nation.nationality') end + # rubocop:disable Style/AsciiComments + ## # Produces a random national flag emoji. # @@ -29,6 +31,7 @@ def nationality def flag sample(translate('faker.nation.flag')).pack('C*').force_encoding('utf-8') end + # rubocop:enable Style/AsciiComments ## # Produces a random national language. diff --git a/lib/faker/japanese_media/one_piece.rb b/lib/faker/japanese_media/one_piece.rb index 4a38245d2e..2826c03c9c 100644 --- a/lib/faker/japanese_media/one_piece.rb +++ b/lib/faker/japanese_media/one_piece.rb @@ -59,7 +59,7 @@ def location # @example # Faker::JapaneseMedia::OnePiece.quote #=> "ONE PIECE IS REAL!" # - # @faker.version 1.8.5 + # @faker.version 1.8.5 def quote fetch('one_piece.quotes') end diff --git a/lib/faker/movies/star_wars.rb b/lib/faker/movies/star_wars.rb index 6935d41640..c3cef7683a 100644 --- a/lib/faker/movies/star_wars.rb +++ b/lib/faker/movies/star_wars.rb @@ -126,7 +126,7 @@ def wookiee_sentence # # @example # Faker::Movies::StarWars.quote(character: "leia_organa") - # #=> "Aren’t you a little short for a Stormtrooper?" + # #=> "Aren't you a little short for a Stormtrooper?" # # @faker.version 1.6.2 def quote(legacy_character = NOT_GIVEN, character: nil) From d8fbd5e663e8a40554ac2532c1f0fb8931035df3 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:10:37 -0600 Subject: [PATCH 12/14] Add YARD docs for Hitchhiker's Guide to the Galaxy. --- .../movies/hitchhikers_guide_to_the_galaxy.rb | 62 +++++++++++++++++++ 1 file changed, 62 insertions(+) diff --git a/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb b/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb index 124e8f2a5c..8d31c65063 100644 --- a/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb +++ b/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb @@ -4,30 +4,92 @@ module Faker class Movies class HitchhikersGuideToTheGalaxy < Base class << self + # Produces a character from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.character #=> "Marvin" + # + # @faker.version 1.8.0 def character fetch('hitchhikers_guide_to_the_galaxy.characters') end + # Produces a location from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.location + # #=> "Arthur Dent's house" + # + # @faker.version 1.8.0 def location fetch('hitchhikers_guide_to_the_galaxy.locations') end + # Produces a Marvin quote from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.marvin_quote + # #=> "Life? Don't talk to me about life." + # + # @faker.version 1.8.0 def marvin_quote fetch('hitchhikers_guide_to_the_galaxy.marvin_quote') end + # Produces a planet from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.planet + # #=> "Magrathea" + # + # @faker.version 1.8.0 def planet fetch('hitchhikers_guide_to_the_galaxy.planets') end + # Produces a quote from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.quote + # #=> "In the beginning, the Universe was created. This has made a lot of people very angry and been widely regarded as a bad move." + # + # @faker.version 1.8.0 def quote fetch('hitchhikers_guide_to_the_galaxy.quotes') end + # Produces a species from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.specie + # #=> "Perfectly Normal Beast" + # + # @faker.version 1.8.0 def specie fetch('hitchhikers_guide_to_the_galaxy.species') end + # Produces a starship from The Hitchhiker's Guide to the Galaxy. + # + # @return [String] + # + # @example + # Faker::Movies::HitchhikersGuideToTheGalaxy.starship + # #=> "Vogon Constructor Fleet" + # + # @faker.version 1.8.0 def starship fetch('hitchhikers_guide_to_the_galaxy.starships') end From 202d671aaefe4e4acc511452c67ea9bb9540bfd9 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:41:13 -0600 Subject: [PATCH 13/14] Fix missing double-hashes at the start of doc blocks. --- lib/faker/movies/back_to_the_future.rb | 3 +++ lib/faker/movies/ghostbusters.rb | 3 +++ lib/faker/movies/harry_potter.rb | 6 ++++++ lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb | 7 +++++++ lib/faker/movies/lebowski.rb | 3 +++ lib/faker/movies/lord_of_the_rings.rb | 3 +++ lib/faker/movies/princess_bride.rb | 2 ++ lib/faker/movies/star_wars.rb | 9 +++++++++ lib/faker/movies/v_for_vendetta.rb | 3 +++ 9 files changed, 39 insertions(+) diff --git a/lib/faker/movies/back_to_the_future.rb b/lib/faker/movies/back_to_the_future.rb index 35c89614a1..8aad8936d2 100644 --- a/lib/faker/movies/back_to_the_future.rb +++ b/lib/faker/movies/back_to_the_future.rb @@ -4,6 +4,7 @@ module Faker class Movies class BackToTheFuture < Base class << self + ## # Produces a character from Back to the Future. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('back_to_the_future.characters') end + ## # Produces a date from Back to the Future. # # @return [String] @@ -28,6 +30,7 @@ def date fetch('back_to_the_future.dates') end + ## # Produces a quote from Back to the Future. # # @return [String] diff --git a/lib/faker/movies/ghostbusters.rb b/lib/faker/movies/ghostbusters.rb index df3479253c..9e5477a8dd 100644 --- a/lib/faker/movies/ghostbusters.rb +++ b/lib/faker/movies/ghostbusters.rb @@ -4,6 +4,7 @@ module Faker class Movies class Ghostbusters < Base class << self + ## # Produces an actor from Ghostbusters. # # @return [String] @@ -16,6 +17,7 @@ def actor fetch('ghostbusters.actors') end + ## # Produces a character from Ghostbusters. # # @return [String] @@ -28,6 +30,7 @@ def character fetch('ghostbusters.characters') end + ## # Produces a quote from Ghostbusters. # # @return [String] diff --git a/lib/faker/movies/harry_potter.rb b/lib/faker/movies/harry_potter.rb index 51563934d3..0e2e39efd6 100644 --- a/lib/faker/movies/harry_potter.rb +++ b/lib/faker/movies/harry_potter.rb @@ -4,6 +4,7 @@ module Faker class Movies class HarryPotter < Base class << self + ## # Produces a character from Harry Potter. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('harry_potter.characters') end + ## # Produces a location from Harry Potter. # # @return [String] @@ -28,6 +30,7 @@ def location fetch('harry_potter.locations') end + ## # Produces a quote from Harry Potter. # # @return [String] @@ -40,6 +43,7 @@ def quote fetch('harry_potter.quotes') end + ## # Produces a book from Harry Potter. # # @return [String] @@ -52,6 +56,7 @@ def book fetch('harry_potter.books') end + ## # Produces a house from Harry Potter. # # @return [String] @@ -64,6 +69,7 @@ def house fetch('harry_potter.houses') end + ## # Produces a spell from Harry Potter. # # @return [String] diff --git a/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb b/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb index 8d31c65063..c5a47994a3 100644 --- a/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb +++ b/lib/faker/movies/hitchhikers_guide_to_the_galaxy.rb @@ -4,6 +4,7 @@ module Faker class Movies class HitchhikersGuideToTheGalaxy < Base class << self + ## # Produces a character from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('hitchhikers_guide_to_the_galaxy.characters') end + ## # Produces a location from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -29,6 +31,7 @@ def location fetch('hitchhikers_guide_to_the_galaxy.locations') end + ## # Produces a Marvin quote from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -42,6 +45,7 @@ def marvin_quote fetch('hitchhikers_guide_to_the_galaxy.marvin_quote') end + ## # Produces a planet from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -55,6 +59,7 @@ def planet fetch('hitchhikers_guide_to_the_galaxy.planets') end + ## # Produces a quote from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -68,6 +73,7 @@ def quote fetch('hitchhikers_guide_to_the_galaxy.quotes') end + ## # Produces a species from The Hitchhiker's Guide to the Galaxy. # # @return [String] @@ -81,6 +87,7 @@ def specie fetch('hitchhikers_guide_to_the_galaxy.species') end + ## # Produces a starship from The Hitchhiker's Guide to the Galaxy. # # @return [String] diff --git a/lib/faker/movies/lebowski.rb b/lib/faker/movies/lebowski.rb index c8494ad5d7..7764a3145a 100644 --- a/lib/faker/movies/lebowski.rb +++ b/lib/faker/movies/lebowski.rb @@ -4,6 +4,7 @@ module Faker class Movies class Lebowski < Base class << self + ## # Produces an actor from The Big Lebowski. # # @return [String] @@ -16,6 +17,7 @@ def actor fetch('lebowski.actors') end + ## # Produces a character from The Big Lebowski. # # @return [String] @@ -28,6 +30,7 @@ def character fetch('lebowski.characters') end + ## # Produces a quote from The Big Lebowski. # # @return [String] diff --git a/lib/faker/movies/lord_of_the_rings.rb b/lib/faker/movies/lord_of_the_rings.rb index 1205bdb719..08b6b25318 100644 --- a/lib/faker/movies/lord_of_the_rings.rb +++ b/lib/faker/movies/lord_of_the_rings.rb @@ -4,6 +4,7 @@ module Faker class Movies class LordOfTheRings < Base class << self + ## # Produces a character from Lord of the Rings. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('lord_of_the_rings.characters') end + ## # Produces a location from Lord of the Rings. # # @return [String] @@ -28,6 +30,7 @@ def location fetch('lord_of_the_rings.locations') end + ## # Produces a quote from Lord of the Rings. # # @return [String] diff --git a/lib/faker/movies/princess_bride.rb b/lib/faker/movies/princess_bride.rb index f96fa9ba96..cf8da0497c 100644 --- a/lib/faker/movies/princess_bride.rb +++ b/lib/faker/movies/princess_bride.rb @@ -4,6 +4,7 @@ module Faker class Movies class PrincessBride < Base class << self + ## # Produces a character from The Princess Bride. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('princess_bride.characters') end + ## # Produces a quote from The Princess Bride. # # @return [String] diff --git a/lib/faker/movies/star_wars.rb b/lib/faker/movies/star_wars.rb index c3cef7683a..c565b22211 100644 --- a/lib/faker/movies/star_wars.rb +++ b/lib/faker/movies/star_wars.rb @@ -4,6 +4,7 @@ module Faker class Movies class StarWars < Base class << self + ## # Produces a call squadron from Star Wars. # # @return [String] @@ -16,6 +17,7 @@ def call_squadron sample(call_squadrons) end + ## # Produces a call sign from Star Wars. # # @return [String] @@ -28,6 +30,7 @@ def call_sign numerify(parse('star_wars.call_sign')) end + ## # Produces a call number from Star Wars. # # @return [String] @@ -40,6 +43,7 @@ def call_number sample(call_numbers) end + ## # Produces a character from Star Wars. # # @return [String] @@ -52,6 +56,7 @@ def character sample(characters) end + ## # Produces a droid from Star Wars. # # @return [String] @@ -64,6 +69,7 @@ def droid sample(droids) end + ## # Produces a planet from Star Wars. # # @return [String] @@ -76,6 +82,7 @@ def planet sample(planets) end + ## # Produces a species from Star Wars. # # @return [String] @@ -88,6 +95,7 @@ def specie sample(species) end + ## # Produces a vehicle from Star Wars. # # @return [String] @@ -116,6 +124,7 @@ def wookiee_sentence sentence + sample(['.', '?', '!']) end + ## # Produces a quote from Star Wars. # # @param character [String] The name of a character to derive a quote from. diff --git a/lib/faker/movies/v_for_vendetta.rb b/lib/faker/movies/v_for_vendetta.rb index e66dbb16e6..ccb6d08e45 100644 --- a/lib/faker/movies/v_for_vendetta.rb +++ b/lib/faker/movies/v_for_vendetta.rb @@ -4,6 +4,7 @@ module Faker class Movies class VForVendetta < Base class << self + ## # Produces a character from V For Vendetta. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('v_for_vendetta.characters') end + ## # Produces a speech from V For Vendetta. # # @return [String] @@ -29,6 +31,7 @@ def speech fetch('v_for_vendetta.speeches') end + ## # Produces a quote from V For Vendetta. # # @return [String] From 84f03910f823d8996573e9ff56f32a8ef5ba9541 Mon Sep 17 00:00:00 2001 From: Connor Shea Date: Thu, 19 Sep 2019 20:41:40 -0600 Subject: [PATCH 14/14] Fix it for One Piece as well. --- lib/faker/japanese_media/one_piece.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lib/faker/japanese_media/one_piece.rb b/lib/faker/japanese_media/one_piece.rb index 2826c03c9c..88b6a0ea8a 100644 --- a/lib/faker/japanese_media/one_piece.rb +++ b/lib/faker/japanese_media/one_piece.rb @@ -4,6 +4,7 @@ module Faker class JapaneseMedia class OnePiece < Base class << self + ## # Produces a character from One Piece. # # @return [String] @@ -16,6 +17,7 @@ def character fetch('one_piece.characters') end + ## # Produces a sea from One Piece. # # @return [String] @@ -28,6 +30,7 @@ def sea fetch('one_piece.seas') end + ## # Produces an island from One Piece. # # @return [String] @@ -40,6 +43,7 @@ def island fetch('one_piece.islands') end + ## # Produces a location from One Piece. # # @return [String] @@ -52,6 +56,7 @@ def location fetch('one_piece.locations') end + ## # Produces a quote from One Piece. # # @return [String] @@ -64,6 +69,7 @@ def quote fetch('one_piece.quotes') end + ## # Produces an akuma no mi from One Piece. # # @return [String]