From a23689a6aa738f5dd051d65b9e26e5d6bb7fa332 Mon Sep 17 00:00:00 2001 From: Jamie Winsor Date: Thu, 4 Aug 2011 03:11:56 -0700 Subject: Remove shared functionality that now exists in refinerycms-testing engine --- spec/factories/user.rb | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 spec/factories/user.rb (limited to 'spec/factories') diff --git a/spec/factories/user.rb b/spec/factories/user.rb deleted file mode 100644 index 94fe1d0..0000000 --- a/spec/factories/user.rb +++ /dev/null @@ -1,27 +0,0 @@ -require 'refinerycms/all' -require 'refinery/role' - -Factory.define :user, :class => ::Refinery::User do |u| - u.sequence(:username) { |n| "person#{n}" } - u.sequence(:email) { |n| "person#{n}@cucumber.com" } - u.password "greenandjuicy" - u.password_confirmation "greenandjuicy" -end - -Factory.define :refinery_user, :parent => :user do |u| - u.roles { [ ::Refinery::Role[:refinery] ] } - - u.after_create do |user| - ::Refinery::Plugins.registered.each_with_index do |plugin, index| - user.plugins.create(:name => plugin.name, :position => index) - end - end -end - -Factory.define :refinery_translator, :parent => :user do |u| - u.roles { [ ::Refinery::Role[:refinery], ::Refinery::Role[:translator] ] } - - u.after_create do |user| - user.plugins.create(:name => 'refinery_pages', :position => 0) - end -end -- cgit v1.2.3