Skip to content
Faker is a pure Elixir library for generating fake data.
Elixir
Branch: master
Clone or download
emig and vbrazo Improvements to Faker.Address.Es Module (#300)
* Changes: improvements to Faker.Address.Es

Added: region function
Added:
  * complete the list of spanish regions
  * document source

Fix:
  *use spanish names for street and city names
  *use correct prefixes and siffixes for stret names

* Fix: add missing tests

* Update lib/faker/address/es.ex

Fix english

Co-Authored-By: Vitor Oliveira <vbrazo@gmail.com>
Latest commit 89a8c91 Nov 7, 2019

README.md

Faker

VersionLicenseBuild StatusIssuesDownloadsGitter

Faker is a pure Elixir library for generating fake data.

Quickstart

  • add {:faker, "~> 0.13"} to your deps in mix.exs:

    defp deps do
      [{:faker, "~> 0.13", only: :test}]
    end
  • run:

    mix deps.get
    
  • add Faker.start() to test/test_helper.exs:

    ExUnit.start()
    Faker.start()
  • jump to usage examples.

Requirements

  • OTP 18+
  • Elixir 1.4+

Usage

See documentation and usage examples.

Troubleshooting

  • If you get a message like the one below when you call Faker.Address.city/0, you need to add :faker to your application's mix file, in the applications function, as above.

    ** (FunctionClauseError) no function clause matching in Faker.Address.city_count/1
    lib/faker/address.ex:48: Faker.Address.city_count(nil)
    lib/faker/address.ex:41: Faker.Address.city/0
    

Tools

Faker was designed as a lightweight library, that's why it can be easily used with other tools.

Templating

You can build templates for testing purposes with the Blacksmith project. See the Blacksmith readme for details.

Team

Faker was originally written by Igor Kapkov.

Current list of maintainers:

Thanks

Sponsored by Evil Martians

License

Released under the MIT License.

You can’t perform that action at this time.