Skip to content

factoryboy gem made for tooploox coding challenge

License

Notifications You must be signed in to change notification settings

lucek/factory-boy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

11 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

FactoryBoy

Simple, FactoryGirl inspired gem written for ToopLoox coding challenge

Installation

Add this line to your application's Gemfile:

gem 'factoryboy'

And then execute:

$ bundle

Or install it yourself as:

$ gem install factoryboy

Usage examples

FactoryBoy.define_factory(:user) do
  name "foobar"
end

FactoryBoy.build(:user) # => #<User:0x007fb98492834 @name="foobar">
FactoryBoy.define_factory(:admin, class: User) do
  name "foobar"
  admin true
end

FactoryBoy.build(:admin) # => #<User:0x007fb98492834 @name="foobar" @admin=true>

About

factoryboy gem made for tooploox coding challenge

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages