Skip to content
Browse files

Fixed problem when fixture_path is not always defined (incidentally, …

…only when ActiveRecord is according to test_help.rb).
  • Loading branch information...
1 parent 5088f8c commit f0ee9e68891a6436946784d5a7e2124040bc14b4 @parndt committed Mar 13, 2012
Showing with 3 additions and 1 deletion.
  1. +3 −1 railties/lib/rails/generators/rails/plugin_new/templates/test/test_helper.rb
View
4 railties/lib/rails/generators/rails/plugin_new/templates/test/test_helper.rb
@@ -10,4 +10,6 @@
Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each { |f| require f }
# Load fixtures from the engine
-ActiveSupport::TestCase.fixture_path = File.expand_path("../fixtures", __FILE__)
+if ActiveSupport::TestCase.method_defined?(:fixture_path)
+ ActiveSupport::TestCase.fixture_path = File.expand_path("../fixtures", __FILE__)
+end

0 comments on commit f0ee9e6

Please sign in to comment.
Something went wrong with that request. Please try again.