From 31df5737ad6a177b256a9d771e8492aa5b34a7e0 Mon Sep 17 00:00:00 2001 From: Jim Myhrberg Date: Tue, 1 Mar 2011 23:36:33 +0000 Subject: [PATCH] added rspec, yard, and console task to Rakefile --- Rakefile | 36 ++++++++++++++++++++++++++++++++++++ 1 file changed, 36 insertions(+) diff --git a/Rakefile b/Rakefile index 14cfe0b..ab78217 100644 --- a/Rakefile +++ b/Rakefile @@ -1,2 +1,38 @@ require 'bundler' Bundler::GemHelper.install_tasks + +# +# Rspec +# + +require 'rspec/core/rake_task' +RSpec::Core::RakeTask.new(:spec) do |spec| + spec.pattern = 'spec/**/*_spec.rb' +end + +task :default => [:start, :spec, :stop] + + +# +# Yard +# + +begin + require 'yard' + YARD::Rake::YardocTask.new +rescue LoadError + task :yardoc do + abort "YARD is not available. In order to run yardoc, you must: sudo gem install yard" + end +end + + +# +# Misc. +# + +desc "Start an irb console with Redistat pre-loaded." +task :console do + exec "irb -r spec/spec_helper" +end +task :c => :console