module Faker::Config

Attributes

locale[W]
random[W]

Public Class Methods

locale() click to toggle source
# File lib/faker.rb, line 22
def locale
  # Because I18n.locale defaults to :en, if we don't have :en in our available_locales, errors will happen
  @locale || (I18n.available_locales.include?(I18n.locale) ? I18n.locale : I18n.available_locales.first)
end
own_locale() click to toggle source
# File lib/faker.rb, line 27
def own_locale
  @locale
end
random() click to toggle source
# File lib/faker.rb, line 31
def random
  @random || Random.new
end