Skip to content

Commit

Permalink
Testing against diff versions of rails
Browse files Browse the repository at this point in the history
  • Loading branch information
TrangPham committed Apr 21, 2015
1 parent ede5cd4 commit 8a7f115
Show file tree
Hide file tree
Showing 4 changed files with 87 additions and 1 deletion.
10 changes: 10 additions & 0 deletions .travis.yml
Expand Up @@ -14,10 +14,20 @@ rvm:
gemfile:
- Gemfile
- gemfiles/Gemfile.ruby1.9.3
- gemfiles/Gemfile.rails3.2
- gemfiles/Gemfile.rails4.1
matrix:
exclude:
- rvm: 1.9.3
gemfile: Gemfile
- rvm: 1.9.3
gemfile: gemfiles/Gemfile.rails3.2
- rvm: 1.9.3
gemfile: gemfiles/Gemfile.rails4.1
- env: DB=
gemfile: gemfiles/Gemfile.rails3.2
- env: DB=
gemfile: gemfiles/Gemfile.rails4.1
- rvm: 2.0.0
gemfile: gemfiles/Gemfile.ruby1.9.3
- rvm: 2.1.2
Expand Down
38 changes: 38 additions & 0 deletions gemfiles/Gemfile.rails3.2
@@ -0,0 +1,38 @@
source "https://rubygems.org"

group :development, :test do
gem 'rake'
gem 'mongoid', '2.6.0'
gem 'bson_ext', platforms: :ruby
gem 'geoip'
gem 'rubyzip'
gem 'rails', '>= 3.2'
gem 'test-unit' # needed for Ruby >=2.2.0

gem 'byebug', platforms: :mri

platforms :jruby do
gem 'jruby-openssl'
gem 'jgeoip'
end

platforms :rbx do
gem 'rubysl', '~> 2.0'
gem 'rubysl-test-unit'
end
end

group :test do
gem 'sqlite3', :platform => [:ruby, :mswin, :mingw]

platforms :ruby do
gem 'pg'
gem 'mysql2'
end

platforms :jruby do
gem 'jdbc-mysql'
gem 'jdbc-sqlite3'
gem 'activerecord-jdbcpostgresql-adapter'
end
end
38 changes: 38 additions & 0 deletions gemfiles/Gemfile.rails4.1
@@ -0,0 +1,38 @@
source "https://rubygems.org"

group :development, :test do
gem 'rake'
gem 'mongoid', '4.0.2'
gem 'bson_ext', platforms: :ruby
gem 'geoip'
gem 'rubyzip'
gem 'rails', '>= 4.1'
gem 'test-unit' # needed for Ruby >=2.2.0

gem 'byebug', platforms: :mri

platforms :jruby do
gem 'jruby-openssl'
gem 'jgeoip'
end

platforms :rbx do
gem 'rubysl', '~> 2.0'
gem 'rubysl-test-unit'
end
end

group :test do
gem 'sqlite3', :platform => [:ruby, :mswin, :mingw]

platforms :ruby do
gem 'pg'
gem 'mysql2'
end

platforms :jruby do
gem 'jdbc-mysql'
gem 'jdbc-sqlite3'
gem 'activerecord-jdbcpostgresql-adapter'
end
end
2 changes: 1 addition & 1 deletion test/unit/logger_test.rb
Expand Up @@ -18,7 +18,7 @@ def teardown

def test_set_logger_logs
assert_equal nil, Geocoder.log(:warn, "should log")
assert_equal "should log\n", @tempfile.read
assert_match /should log\n$/, @tempfile.read
end

def test_set_logger_does_not_log_severity_too_low
Expand Down

0 comments on commit 8a7f115

Please sign in to comment.