Giter Club home page Giter Club logo

swiftyfakerold's Introduction

SwiftyFaker

Build Status Join the chat at https://gitter.im/boxenjim/SwiftyFaker Carthage compatible

A fake data generator written in Swift. Inspired by and Aspiring to be as amazing as the Ruby gem, Faker.

Usage

Faker.Name.name() -> "Nellie Buckridge Jr."
Faker.Lorem.sentence() -> "voluptas consequatur magnam harum."

Faker.Address

Faker.Address.buildingNumber() -> "220"
Faker.Address.city() -> "Lake Derrickport"
Faker.Address.cityPrefix() -> "Port"
Faker.Address.citySuffix() -> "ton"
Faker.Address.country() -> "Zambia"
Faker.Address.countyCode() -> "FO"
Faker.Address.latitude() -> "-17.1575853332711"
Faker.Address.longitude() -> "74.6779822763161"
Faker.Address.postcode() -> "10816-7015"
Faker.Address.secondaryAddress() -> "Suite 866"
Faker.Address.state() -> "Missouri"
Faker.Address.stateAbbr() -> "AK"
Faker.Address.streetAddress() -> "659 Blanda Plains"
Faker.Address.steetName() -> "Casandra Shore"
Faker.Address.streetSuffix() -> "Avenue"
Faker.Address.timezone() -> "Europe/Bucharest"
Faker.Address.zip() -> "53097-3343"
Faker.Address.zipCode() -> "82782"

Faker.App

Faker.App.name() -> "Alphazap"
Faker.App.appVersion() -> "1.5.2"
Faker.App.author() -> "Otha Braun"

Faker.Book

Faker.Book.title() -> "The Zookeeper and Her Tiger"
Faker.Book.author() -> "Janie Bashirian"
Faker.Book.publisher() -> "Parker Publishing"

Faker.Business

Faker.Business.creditCardNumber() -> "1234-2121-1221-1211"
Faker.Business.creditCardExpiry() -> 2019-10-05 06:00:00 +0000
Faker.Business.creditCardType() -> "discover"

Faker.Commerce

Faker.Commerce.color() -> "maroon"
Faker.Commerce.department() -> "Electronics & Garden"
Faker.Commerce.productName() -> "Aerodynamic Iron Computer"
Faker.Commerce.material() -> "Silk"
Faker.Commerce.price() -> 3.72
Faker.Commerce.product() -> Bag

Faker.Company

Faker.Company.name() -> "Labadie-Wisoky"
Faker.Comany.suffix() -> "and Sons"
Faker.Company.catchPhrase() -> "Public-key context-sensitive core"
Faker.Company.buzzword() -> "Enhanced"
Faker.Company.bs() -> "streamline scalable e-business"
Faker.Company.ein() -> "82-8784359"
Faker.Company.dunNumber() -> "57-381-4056"
Faker.Company.logo() -> "http://pigment.github.io/fake-logos/logos/medium/color/10.png"
Faker.Company.swedishOrganisationNumber() -> "57189359064"

Faker.Hacker

Faker.Hacker.saySomethingSmart() -> "We need to input the redundant IB microchip!"
Faker.Hacker.abbreviation() -> "FTP"
Faker.Hacker.adjective() -> "open-source"
Faker.Hacker.noun() -> "driver"
Faker.Hacker.verb() -> "parse"
Faker.Hacker.ingverb() -> "overriding"

Faker.Lorem

Faker.Lorem.word() -> "sed"
Faker.Lorem.words() -> ["vel", "officia", "perferendis"]
Faker.Lorem.sentence() -> "dicta ipsum eveniet recusandae."

Faker.Name

Faker.Name.name() -> "Mrs. Grant Wilkinson"
Faker.Name.firstName() -> "Willy"
Faker.Name.lastName() -> "Rolfson"
Faker.Name.prefix() -> "Ms."
Faker.Name.suffix() -> "II"
Faker.Name.Title() -> "Future Identity Inspector"

Faker.Number

Faker.Number.number() -> 74038
Faker.Number.number(6) -> 413010
Faker.Number.decimal(5) -> 50054.36
Faker.Number.decimal(3, digitsAfter: 5) -> 495.58939
Faker.Number.hexadecimal(4) ->
Faker.Number.between(0...1000) -> 193
Faker.Number.between(0.0, max: 1000.00) -> 970.784187725463
Faker.Number.positive() -> 996.451204905439
Faker.Number.negative() -> -1996.75554450195
Faker.Number.digit() -> 4

Faker.PhoneNumber

Faker.PhoneNumber.phoneNumber() -> "513-713-9291 x308"
Faker.PhoneNumber.cellPhone() -> "551.541.6329"
Faker.PhoneNumber.areaCode() -> "551"
Faker.PhoneNumber.exchangeCode() -> "318"
Faker.PhoneNumber.subscriberNumber() -> "2316"
Faker.PhoneNumber.extensionNumber() -> "697"

Faker.SlackEmoji

Faker.SlackEmoji.people() -> ":kissing:"
Faker.SlackEmoji.nature() -> ":rabbit2:"
Faker.SlackEmoji.foodAndDrink() -> ":pineapple:"
Faker.SlackEmoji.celebration() -> ":broken_heart:"
Faker.SlackEmoji.activity() -> ":rowboat:"
Faker.SlackEmoji.travelAndPlaces() -> ":articulated_lorry:"
Faker.SlackEmoji.objectsAndSymbols() -> ":wrench:"
Faker.SlackEmoji.custom() -> ":simple_smile:"
Faker.SlackEmoji.emoji() -> ":suspect:"

Faker.Team

Faker.Team.creature() -> "chickens"
Faker.Team.name() -> "Washington sheep"
Faker.Team.sport() -> "wrestling"
Faker.Team.state() -> "Utah"

Faker.University

Faker.University.name() -> "Eastern Indiana Institute"
Faker.University.prefix() -> "West"
Faker.University.suffix() -> "University"

Installation

Carthage

Add the following line to your Cartfile.

github "boxenjim/SwiftyFaker"

Note: to use SwiftyFaker with unit/ui tests be sure to read and follow, Adding frameworks to unit tests or a framework of the Carthage documentation

Tests

Open the Xcode project and press โŒ˜-U to run the tests.

Contributing

  • Create something awesome, make the code better, add some functionality, whatever (this is the hardest part).
  • Fork it
  • Create new branch to make your changes
  • Commit all your changes to your branch
  • Submit a pull request
  • There's a ton of people out there way smarter than me, please contribute

Contact

Feel free to get in touch.

  • Gitter: Join the chat at https://gitter.im/boxenjim/SwiftyFaker
  • Twitter: Twitter

swiftyfakerold's People

Watchers

Jim Schultz avatar

swiftyfakerold's Issues

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.