lib/roar-rails.rb in roar-rails-0.0.9 vs lib/roar-rails.rb in roar-rails-0.0.10
- old
+ new
@@ -15,13 +15,26 @@
autoload("Hypermedia", "roar/representer/feature/hypermedia")
end
end
+
module Roar
module Rails
+ def self.rails3_0?
+ ::Rails::VERSION::MINOR == 0
+ end
+
+ if rails3_0?
+ require 'roar/rails/rails3_0_strategy'
+ else
+ require 'roar/rails/rails3_1_strategy'
+ end
+
autoload("TestCase", "roar/rails/test_case")
autoload("ControllerAdditions", "roar/rails/controller_additions")
autoload("Responder", "roar/rails/responder")
autoload("ModelMethods", "roar/rails/responder")
end
end
+
+