Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Be friendlier when you don't have the latest test dependencies [#63 s…

…tate:resolved]
  • Loading branch information...
commit 0266f07d6b7abebc7ec766d986115948e19fe8e6 1 parent d618715
@foca foca authored
Showing with 25 additions and 9 deletions.
  1. +6 −0 Rakefile
  2. +19 −9 test/helpers.rb
View
6 Rakefile
@@ -48,6 +48,12 @@ namespace :test do
end
end
end
+
+ desc "Install all gems on which the tests depend on"
+ task :install_dependencies do
+ system 'sudo gem install redgreen rr mocha ruby-debug dm-sweatshop'
+ system 'sudo gem install -s http://gems.github.com jeremymcanally-context jeremymcanally-matchy jeremymcanally-pending foca-storyteller'
+ end
end
namespace :db do
View
28 test/helpers.rb
@@ -1,14 +1,24 @@
require File.dirname(__FILE__) + "/../lib/integrity"
-require "test/unit"
-require "redgreen"
-require "context"
-require "storyteller"
-require "pending"
-require "matchy"
-require "rr"
-require "mocha"
-require "ruby-debug"
+begin
+ require "test/unit"
+ require "redgreen"
+ require "context"
+ require "storyteller"
+ require "pending"
+ require "matchy"
+ require "rr"
+ require "mocha"
+ require "ruby-debug"
+rescue LoadError
+ puts "You're missing some gems required to run the tests."
+ puts "Please run `rake test:install_dependencies`"
+ puts
+ puts "Thanks :)"
+ puts
+
+ exit 1
+end
require File.dirname(__FILE__) / "helpers" / "expectations"
require File.dirname(__FILE__) / "helpers" / "fixtures"
Please sign in to comment.
Something went wrong with that request. Please try again.