Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

More cleanup - require rubygems outside of the codebase

  • Loading branch information...
commit bfdf92388bda4e6bd1952cbb94193e8dc71c2dbb 1 parent 82063df
@nicksieger nicksieger authored
View
8 Rakefile
@@ -70,7 +70,7 @@ begin
RCov::VerifyTask.new(:rcov) do |t|
# Can't get threshold up to 100 unless RSpec backwards compatibility
# code is dropped
- t.threshold = 98
+ t.threshold = 95
t.require_exact_threshold = false
end
rescue LoadError
@@ -85,9 +85,9 @@ task :generate_output do
rm_rf "acceptance/reports"
ENV['CI_REPORTS'] = "acceptance/reports"
begin
- `ruby -Ilib -rci/reporter/rake/test_unit_loader acceptance/test_unit_example_test.rb` rescue puts "Warning: #{$!}"
- `ruby -Ilib -S #{@spec_bin} --require ci/reporter/rake/rspec_loader --format CI::Reporter::RSpec acceptance/rspec_example_spec.rb` rescue puts "Warning: #{$!}"
- `ruby -Ilib -rci/reporter/rake/cucumber_loader -S cucumber --format CI::Reporter::Cucumber acceptance/cucumber` rescue puts "Warning: #{$!}"
+ `ruby -Ilib -rubygems -rci/reporter/rake/test_unit_loader acceptance/test_unit_example_test.rb` rescue puts "Warning: #{$!}"
+ `ruby -Ilib -rubygems -S #{@spec_bin} --require ci/reporter/rake/rspec_loader --format CI::Reporter::RSpec acceptance/rspec_example_spec.rb` rescue puts "Warning: #{$!}"
+ `ruby -Ilib -rubygems -rci/reporter/rake/cucumber_loader -S cucumber --format CI::Reporter::Cucumber acceptance/cucumber` rescue puts "Warning: #{$!}"
ensure
ENV.delete 'CI_REPORTS'
end
View
9 lib/ci/reporter/cucumber.rb
@@ -3,17 +3,10 @@
# software license details.
require 'ci/reporter/core'
-tried_gem = false
+require 'cucumber'
begin
- require 'cucumber'
require 'cucumber/ast/visitor'
rescue LoadError
- unless tried_gem
- tried_gem = true
- require 'rubygems'
- gem 'cucumber'
- retry
- end
end
module CI
View
6 lib/ci/reporter/test_suite.rb
@@ -66,12 +66,6 @@ def finish
# Creates the xml builder instance used to create the report xml document.
def create_builder
- begin
- require 'rubygems'
- gem 'builder'
- rescue LoadError
- end
-
require 'builder'
# :escape_attrs is obsolete in a newer version, but should do no harm
Builder::XmlMarkup.new(:indent => 2, :escape_attrs => true)
Please sign in to comment.
Something went wrong with that request. Please try again.