Sha256: 7d4d79b955439cb8eab767a1957a37fb199ba037e53ffac67df4e54eba75f829
Contents?: true
Size: 742 Bytes
Versions: 4
Compression:
Stored size: 742 Bytes
Contents
# encoding: utf-8 require 'ffaker/address' module FFaker module AddressUS include FFaker::Address extend ModuleUtils extend self ZIP_FORMATS = ['#####', '#####-####'].freeze CONTINENTAL_STATE = (STATE - %w(Hawaii Alaska)) CONTINENTAL_STATE_ABBR = (STATE_ABBR - %w(HI AK)) def zip_code FFaker.numerify(fetch_sample(ZIP_FORMATS)) end def state fetch_sample(STATE) end def state_abbr fetch_sample(STATE_ABBR) end def state_and_territories_abbr fetch_sample(STATE_AND_TERRITORIES_ABBR) end def continental_state fetch_sample(CONTINENTAL_STATE) end def continental_state_abbr fetch_sample(CONTINENTAL_STATE_ABBR) end end end
Version data entries
4 entries across 4 versions & 1 rubygems
Version | Path |
---|---|
ffaker-2.6.0 | lib/ffaker/address_us.rb |
ffaker-2.5.0 | lib/ffaker/address_us.rb |
ffaker-2.4.0 | lib/ffaker/address_us.rb |
ffaker-2.3.0 | lib/ffaker/address_us.rb |