Permalink
Browse files

Minor cleanup of JRuby compatibility

* Formatting, whitespace errors
* Gem dependency configurations
  • Loading branch information...
1 parent ea80f3e commit 62f67149824fb1ce3aa2a224c0114dd3d31e7cbb @karmi committed Jan 4, 2013
Showing with 8 additions and 14 deletions.
  1. +2 −9 Gemfile
  2. +1 −1 test/test_helper.rb
  3. +2 −2 test/unit/http_client_test.rb
  4. +3 −2 tire.gemspec
View
11 Gemfile
@@ -3,15 +3,8 @@ source "http://rubygems.org"
# Specify your gem's dependencies in tire.gemspec
gemspec
-unless defined?(RUBY_VERSION) && RUBY_VERSION < '1.9'
- gem "turn", "~> 0.9"
-end
-
platform :jruby do
gem "jdbc-sqlite3"
gem "activerecord-jdbcsqlite3-adapter"
-
- if defined?(RUBY_VERSION) && RUBY_VERSION < '1.9'
- gem "json"
- end
-end
+ gem "json" if defined?(RUBY_VERSION) && RUBY_VERSION < '1.9'
+end
View
2 test/test_helper.rb
@@ -26,7 +26,7 @@
end
require 'shoulda'
-require 'turn/autorun' unless ENV["TM_FILEPATH"] || defined?(RUBY_VERSION) && RUBY_VERSION < '1.9'
+require 'turn/autorun' unless ENV["TM_FILEPATH"] || JRUBY
require 'mocha'
require 'active_support/core_ext/hash/indifferent_access'
View
4 test/unit/http_client_test.rb
@@ -47,7 +47,7 @@ class ClientTest < Test::Unit::TestCase
if defined?(Curl)
require 'tire/http/clients/curb'
-
+
context "Curb" do
setup do
Configuration.client Client::Curb
@@ -70,8 +70,8 @@ class ClientTest < Test::Unit::TestCase
end
end
- end
+ end
end
end
View
5 tire.gemspec
@@ -34,21 +34,22 @@ Gem::Specification.new do |s|
# = Development dependencies
#
- s.add_development_dependency "bundler", "~> 1.0"
+ s.add_development_dependency "bundler", "~> 1.0"
s.add_development_dependency "shoulda"
s.add_development_dependency "mocha"
s.add_development_dependency "minitest", "~> 2.12"
s.add_development_dependency "activerecord", ">= 3.0"
s.add_development_dependency "mongoid", "~> 2.2"
s.add_development_dependency "redis-persistence"
s.add_development_dependency "faraday"
-
+
unless defined?(JRUBY_VERSION)
s.add_development_dependency "yajl-ruby", "~> 1.0"
s.add_development_dependency "sqlite3"
s.add_development_dependency "bson_ext"
s.add_development_dependency "curb"
s.add_development_dependency "oj"
+ s.add_development_dependency "turn", "~> 0.9"
end
s.description = <<-DESC

0 comments on commit 62f6714

Please sign in to comment.