Created
August 2, 2013 23:32
-
-
Save futhr/6144289 to your computer and use it in GitHub Desktop.
A quick way to create sample data testing Spree extensions.
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
# in your code | |
binding.pry | |
# pry console | |
require 'factory_girl' | |
require 'spree/testing_support/factories' # spree core factories | |
FactoryGirl.find_definitions # extension factories | |
# orders | |
FactoryGirl.create :order_with_totals | |
FactoryGirl.create :order_with_line_items | |
FactoryGirl.create :completed_order_with_totals | |
FactoryGirl.create :order_ready_to_ship | |
FactoryGirl.create :shipped_order | |
# more ... |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment