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

Adds Smashing Pumpkins to the Music module #2817

Merged
merged 1 commit into from
Nov 1, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
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
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -411,6 +411,7 @@ gem 'faker', :git => 'https://github.com/faker-ruby/faker.git', :branch => 'main
- [Faker::Music::Prince](doc/music/prince.md)
- [Faker::Music::RockBand](doc/music/rock_band.md)
- [Faker::Music::Rush](doc/music/rush.md)
- [Faker::Music::SmashingPumpkins](doc/music/smashing_pumpkins.md)
- [Faker::Music::UmphreysMcgee](doc/music/umphreys_mcgee.md)
</details>

Expand Down
11 changes: 11 additions & 0 deletions doc/music/smashing_pumpkins.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Faker::Music::SmashingPumpkins

```ruby
Faker::Music::SmashingPumpkins.musician #=> "D'arcy Wretsky"

Faker::Music::SmashingPumpkins.album #=> "Mellon Collie and the Infinite Sadness"

Faker::Music::SmashingPumpkins.song #=> "Disarm"

Faker::Music::SmashingPumpkins.lyric #=> "The world is a vampire, sent to drain, secret destroyers, hold you up to the flames"
```
64 changes: 64 additions & 0 deletions lib/faker/music/smashing_pumpkins.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,64 @@
# frozen_string_literal: true

require_relative 'music'

module Faker
class Music
class SmashingPumpkins < Base
class << self
##
# Produces the name of a member of the Smashing Pumpkins (current and former)
#
# @return [String]
#
# @example
# Faker::Music::SmashingPumpkins.musician #=> "Billy Corgan"
#
# @faker.version next
def musician
fetch('smashing_pumpkins.musicians')
end

##
# Produces the name of an album by the Smashing Pumpkins.
#
# @return [String]
#
# @example
# Faker::Music::SmashingPumpkins.album #=> "Siamese Dream"
#
# @faker.version next
def album
fetch('smashing_pumpkins.albums')
end

##
# Produces a random Smashing Pumpkins song lyric.
#
# @return [String]
#
# @example
# Faker::Music::SmashingPumpkins.lyric #=> "Despite all my rage, I am still just a rat in a cage"
# Faker::Music::SmashingPumpkins.lyric #=> "Breathin' underwater, and livin' under glass"
#
# @faker.version next
def lyric
fetch('smashing_pumpkins.lyric')
end

##
# Produces the name of a song by the Smashing Pumpkins.
#
# @return [String]
#
# @example
# Faker::Music::SmashingPumpkins.song #=> "Stand Inside My Love"
#
# @faker.version next
def song
fetch('smashing_pumpkins.songs')
end
end
end
end
end
Loading