Created
April 13, 2009 19:51
-
-
Save ntreadway/94672 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#factories setup w/ cucumber. | |
#(env.rb) | |
require 'factory_girl' | |
Before do | |
require File.join(RAILS_ROOT, 'test', 'factories') | |
end | |
#Then in your (setups.rb) you can create your object using one line. | |
Given /I am logged in as a user/ do | |
@user = Factory(:user) | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment