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 YARD doc for Faker::Coin #1803

Merged
merged 3 commits into from Nov 14, 2019
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
18 changes: 18 additions & 0 deletions lib/faker/default/coin.rb
Expand Up @@ -3,10 +3,28 @@
module Faker
class Coin < Base
class << self
##
# Retrieves a random coin from any country.
#
# @return [String]
#
# @example
# Faker::Coin.name #=> "Brazilian Real"
#
# @faker.version 2.6.0
sap1enza marked this conversation as resolved.
Show resolved Hide resolved
def name
fetch('currency.name')
end

##
# Retrieves a face to a flipped coin
#
# @return [String]
#
# @example
# Faker::Coin.flip #=> "Heads"
#
# @faker.version 2.6.0
sap1enza marked this conversation as resolved.
Show resolved Hide resolved
def flip
fetch('coin.flip')
end
Expand Down