Permalink
Browse files

limit certain test tools to MRI 1.9

  • Loading branch information...
phlipper committed Dec 31, 2012
1 parent d42d8bf commit 6ffa1608649394498447ab86f17b4d7af6579350
Showing with 26 additions and 13 deletions.
  1. +1 −1 .travis.yml
  2. +6 −0 Gemfile
  3. +0 −3 forem-kramdown.gemspec
  4. +8 −0 test/ci/ci_runner.sh
  5. +11 −9 test/minitest_helper.rb
View
@@ -7,4 +7,4 @@ rvm:
- rbx-19mode
env:
- CI=true JRUBY_OPTS=--1.9 RBXOPT=-X19
-script: "bundle exec rake test && bundle exec cane"
+script: "./test/ci/ci_runner.sh"
View
@@ -1,3 +1,9 @@
source "https://rubygems.org"
gemspec
+
+platform :mri_19 do
+ gem "cane", "~> 2.5.0"
+ gem "coveralls", "~> 0.5.5"
+ gem "simplecov", "~> 0.7.1"
+end
View
@@ -22,9 +22,6 @@ Gem::Specification.new do |gem|
gem.add_dependency "kramdown", "~> 0.14.1"
gem.add_dependency "nokogiri", "~> 1.5.6"
- gem.add_development_dependency "cane", "~> 2.5.0"
- gem.add_development_dependency "coveralls", "~> 0.5.5"
gem.add_development_dependency "minitest", "~> 4.3.0"
gem.add_development_dependency "rake", "~> 10.0.0"
- gem.add_development_dependency "simplecov", "~> 0.7.1"
end
View
@@ -0,0 +1,8 @@
+engine=$(ruby -e 'puts RUBY_ENGINE')
+
+case $engine in
+ "ruby" )
+ bundle exec rake test && bundle exec cane;;
+ * )
+ bundle exec rake test;;
+esac
View
@@ -1,14 +1,16 @@
-require "simplecov"
-require "coveralls"
+if RUBY_ENGINE == "ruby" && RUBY_VERSION > "1.9"
+ require "simplecov"
+ require "coveralls"
-SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
- SimpleCov::Formatter::HTMLFormatter,
- Coveralls::SimpleCov::Formatter
-]
+ SimpleCov.formatter = SimpleCov::Formatter::MultiFormatter[
+ SimpleCov::Formatter::HTMLFormatter,
+ Coveralls::SimpleCov::Formatter
+ ]
-SimpleCov.start do
- add_filter "test"
- command_name "MiniTest"
+ SimpleCov.start do
+ add_filter "test"
+ command_name "MiniTest"
+ end
end
require "minitest/autorun"

0 comments on commit 6ffa160

Please sign in to comment.