Skip to content
This repository
Browse code

Keep rake functional in absence of bundler.

Even without bundler it is possible to run the tests.
  • Loading branch information...
commit 4d3c4b044b64e1117f7bd08579a9f90abd838b6f 1 parent ee869ff
Oleg Pudeyev authored August 25, 2011

Showing 1 changed file with 8 additions and 2 deletions. Show diff stats Hide diff stats

  1. 10  Rakefile
10  Rakefile
... ...
@@ -1,5 +1,11 @@
1  
-require 'bundler'
2  
-Bundler::GemHelper.install_tasks
  1
+begin
  2
+  require 'bundler'
  3
+rescue LoadError => e
  4
+  warn("warning: Could not load bundler: #{e}")
  5
+  warn("         Some rake tasks will not be defined")
  6
+else
  7
+  Bundler::GemHelper.install_tasks
  8
+end
3 9
 
4 10
 require 'rake/testtask'
5 11
 Rake::TestTask.new(:test) do |test|

0 notes on commit 4d3c4b0

Please sign in to comment.
Something went wrong with that request. Please try again.