spec/support/controller_macros.rb in enju_barcode-0.0.1 vs spec/support/controller_macros.rb in enju_barcode-0.0.2
- old
+ new
@@ -1,24 +1,24 @@
module ControllerMacros
def login_admin
before(:each) do
@request.env["devise.mapping"] = Devise.mappings[:admin]
- sign_in Factory.create(:admin)
+ sign_in FactoryGirl.create(:admin)
end
end
def login_librarian
before(:each) do
@request.env["devise.mapping"] = Devise.mappings[:user]
- user = Factory.create(:librarian)
+ user = FactoryGirl.create(:librarian)
sign_in user
end
end
def login_user
before(:each) do
@request.env["devise.mapping"] = Devise.mappings[:user]
- user = Factory.create(:user)
+ user = FactoryGirl.create(:user)
sign_in user
end
end
def login_fixture_admin