diff --git a/.gitignore b/.gitignore index 2ef238e..24e357b 100644 --- a/.gitignore +++ b/.gitignore @@ -3,4 +3,5 @@ debug.log autotest .rbenv-version Gemfile.lock -debug.log \ No newline at end of file +debug.log +*.gem \ No newline at end of file diff --git a/Gemfile b/Gemfile index a961ac4..0cd8376 100644 --- a/Gemfile +++ b/Gemfile @@ -4,6 +4,7 @@ source 'http://gems.github.com/' spec = eval(File.read('grouped_scope.gemspec')) ar_version = spec.dependencies.detect{ |d|d.name == 'activerecord' }.requirement.to_s +ar_version = ENV['RAILS_VERSION'] || ar_version gem 'sqlite3', '1.3.4' gem 'activerecord', ar_version, :require => 'active_record' diff --git a/grouped_scope.gemspec b/grouped_scope.gemspec index f127b14..faf4d7d 100644 --- a/grouped_scope.gemspec +++ b/grouped_scope.gemspec @@ -9,12 +9,12 @@ Gem::Specification.new do |s| s.email = ['ken@metaskills.net'] s.homepage = 'http://github.com/metaskills/grouped_scope/' s.summary = 'Extends has_many associations to group scope.' - s.description = 'Extends has_many associations to group scope. For ActiveRecord 2.3.x!' + s.description = 'Extends has_many associations to group scope. For ActiveRecord 3.1!' s.files = `git ls-files`.split("\n") - ["grouped_scope.gemspec"] s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n") s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) } s.require_paths = ['lib'] s.rdoc_options = ['--charset=UTF-8'] - s.add_dependency 'activerecord', '~> 3.1.3' + s.add_dependency 'activerecord', '~> 3.1.0' end diff --git a/lib/grouped_scope/version.rb b/lib/grouped_scope/version.rb index ce4226a..12ab0f9 100644 --- a/lib/grouped_scope/version.rb +++ b/lib/grouped_scope/version.rb @@ -1,3 +1,3 @@ module GroupedScope - VERSION = '3.1.0' + VERSION = '3.1.1' end diff --git a/test/grouped_scope/has_many_test.rb b/test/cases/has_many_test.rb similarity index 100% rename from test/grouped_scope/has_many_test.rb rename to test/cases/has_many_test.rb diff --git a/test/grouped_scope/has_many_through_test.rb b/test/cases/has_many_through_test.rb similarity index 100% rename from test/grouped_scope/has_many_through_test.rb rename to test/cases/has_many_through_test.rb diff --git a/test/grouped_scope/reflection_test.rb b/test/cases/reflection_test.rb similarity index 100% rename from test/grouped_scope/reflection_test.rb rename to test/cases/reflection_test.rb diff --git a/test/grouped_scope/self_grouping_test.rb b/test/cases/self_grouping_test.rb similarity index 100% rename from test/grouped_scope/self_grouping_test.rb rename to test/cases/self_grouping_test.rb