我在导轨3中编写测试单元。我包括
group :test do
gem "factory_girl_rails", "1.0.1"
gem "shoulda"
gem 'mocha', '0.13.1'
gem 'database_cleaner'
end
也创建了一些工厂。但应用程序正在加载夹具。下面是我的test_helper。
ENV["RAILS_ENV"] = "test"
require File.expand_path('../../config/environment', __FILE__)
require 'rails/test_help'
require 'shoulda'
require 'mocha'
class ActiveSupport::TestCase
self.use_transactional_fixtures = false
self.use_instantiated_fixtures = false
fixtures :all
end
请帮帮我。