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

Add faker for hiphop artist #1923

Merged
merged 5 commits into from
Oct 5, 2020
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
30 changes: 30 additions & 0 deletions lib/faker/music/hiphop.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
# frozen_string_literal: true

module Faker
class Music
class Hiphop < Base
class << self
##
# Produces Name of HipHop Artist
#
# @return [String]
#
# @example
# Faker::Music::Hiphop.group #=> "OVO"
Copy link
Contributor

Choose a reason for hiding this comment

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

example shows the wrong method

#
# @faker.version 1.9.2
Copy link
Contributor

Choose a reason for hiding this comment

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

should be @faker.version next so that we can just find and replace when this gets merged

def artist
fetch('hiphop.artist')
end

# @example
# Faker::Music::Hiphop.artist #=> "Lil Wayne"
#
Copy link
Contributor

Choose a reason for hiding this comment

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

incomplete DocBlock


Copy link
Contributor

Choose a reason for hiding this comment

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

Extra space here that can be removed

def groups
fetch('hiphop.groups')
end
end
Zeragamba marked this conversation as resolved.
Show resolved Hide resolved
end
end
end
127 changes: 127 additions & 0 deletions lib/locales/en/hiphop.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,127 @@
en:
faker:
hiphop:
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we shift this down to en.faker.music.hiphop?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@Zeragamba got all the comments knocked out.

groups:
- Outcast
- Griselda
- Wu-Tang Clan
- YMCMB
- Maybach Music
- Bad Boyz
- Rock Nation
- Jack Boys
- OVO
- Tribe Call Quest
- Cypress Hill
- Digital Undeground
- Naughty By Nature
- EPMD
- Run-D.M.C
- N.W.A
- Salt & Pepa
- TLC
- G-Unit
- Bone Thugs & Harmony
- Destiny's Child
- Public Enemy
- Mobb Deep
- Eric B. & Rakim
- Fugees
- The Sugarhill Gang
- D12
- Three 6 Mafia
- Migos
- Clipse
- Odd Future
- 2 Live Crew
- The Lox
- Dipset
artist:
- Drake
- Jay-Z
- Lil Wayne
- Travis Scott
- Ice Cube
- Wutang Clan
- Tribe Called Quest
- Nas
- Foxy Brown
- TI
- TPain
- Tory Lanez
- Big Krit
- Joey BadA$$
- A$AP Rocky
- Tyler The Creator
- Frank Ocean
- 50 Cent
- Snoop Dogg
- Wiz Khalifa
- Tupac
- The Notorious B.I.G
- Missy Elliot
- DMX
- Eminem
- Method Man
- Red Man
- Kanye West
- Gucci Mane
- Baby Keem
- Roddy Ricch
- Nipsey Hussle
- Queen Latifah
- Pusha T
- Chief Keef
- Lil Reese
- Lil Peep
- Lil Snupe
- Meek Mill
- Wale
- Busta Rhymes
- Ludacris
- Ashanti
- Shy Glizzy
- Fredo Santana
- Fat Joe
- Don Toliver
- Sheck Wes
- Bobby Smurda
- Dave East
- J Holiday
- Chris Brown
- Omarion
- Fabulous
- Jadakiss
- Nicki Minaj
- Meg The Stallion
- Saweetie
- Larry June
- Quavo
- Offset
- Takeoff
- Stormzy
- xxxTentacion
- Juice Wrld
- Juicy J
- P Diddy
- Young Thug
- Gunna
- Lil Tecca
- Da Baby
- Lil Baby
- Lil Uzi
- 21 Savage
- 2 Chainz
- Craig Mac
- Cardi B
- Chance The Rapper
- Mac Miller
- The Game
- Styles P
- Paul Wall
- Cam'ron
- Jeezy
- Dr. Dre
- Nate Dogg
- Kurupt
- Twista
17 changes: 17 additions & 0 deletions test/faker/music/test_faker_hiphop.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
# frozen_string_literal: true

require_relative '../../test_helper'

class TestFakerHiphop < Test::Unit::TestCase
def setup
@tester = Faker::Music::Hiphop
end

def test_artist
assert @tester.artist.match(/\w+/)
end

def test_groups
assert @tester.groups.match(/\w+/)
end
end