Skip to content

Faker is a Golang package that generates easily accessible fake data.

License

Notifications You must be signed in to change notification settings

AaronMulgrew/GoFaker

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

55 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

GoFaker

Build Status codecov Go Report Card

Faker is a Go package to generate fake data. It can be used for realistic test data. Inspired by Python Faker

Why use this library?

There are many faker libraries out there already. However, none of them are comprehensive, performant and easy to use. The aim of this library is to combine those things into a quick, easy to use and extensible library, using only core Golang libraries to generate the data.

Installation

go get -u github.com/AaronMulgrew/GoFaker

Usage

Simply import the library and generate a Person struct to accessible available data.

package main

import (
  "fmt"
  "github.com/AaronMulgrew/GoFaker"
)

func main() {
  person := faker.GeneratePerson()
  fmt.Println(person.Names.Firstname)
  fmt.Println(person)
}

You can also view the Faker Client for a full list of available structs and other examples.

Currently Supported Data

Person

  • Banking
    • IBAN (Should validate against IBAN validators)
    • Account Number
    • Bank Code (Does not use real bank codes)
  • Automotive
    • Number Plates
  • Names
    • Firstname
    • Surname

Server

  • Files
    • File Location
    • Content Type of File (over 1000 content types supported)
    • Extensions of Files (over 1000 extensions supported)

Currently Supported Regional Data

  • English (United Kingdom)

About

Faker is a Golang package that generates easily accessible fake data.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages