Skip to content
This repository
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 57 lines (44 sloc) 1.529 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56
require 'rubygems'
gem 'jeweler', '>= 1.4.0'
require 'rake'
require 'yaml'

$:.unshift File.expand_path(File.join(File.dirname(__FILE__),'lib'))

require 'rake/rdoctask'
require 'rspec/rails/version'

begin
  require 'jeweler'
  Jeweler::Tasks.new do |gem|
    gem.name = "rspec-rails"
    gem.version = Rspec::Rails::Version::STRING
    gem.summary = "Rspec-2 for Rails-3"
    gem.email = "dchelimsky@gmail.com;chad.humphries@gmail.com"
    gem.homepage = "http://github.com/rspec/rspec-rails"
    gem.authors = ["David Chelimsky", "Chad Humphries"]
    gem.add_dependency "rspec", ">= 2.0.0.a6"
    gem.add_dependency "webrat", ">= 0.7.0"
    # gem is a Gem::Specification... see http://www.rubygems.org/read/chapter/20 for additional settings
  end
  Jeweler::GemcutterTasks.new
rescue LoadError
  puts "Jeweler (or a dependency) not available. Install it with: gem install jeweler"
end


desc 'create app, generate a bunch of stuff, and run rake spec'
task :create_app do |t|
  if File.directory?('./tmp/rails')
    rm_rf "tmp/example_app"
    ruby "./tmp/rails/railties/bin/rails tmp/example_app --dev -m example_app_template.rb"
  else
    puts <<-MESSAGE

You need to install rails in ./tmp/rails before you can run the
#{t.name} task:
git clone git://github.com/rails/rails tmp/rails

(We'll automate this eventually, but running 'git clone' from rake in this
project is mysteriously full of fail)

MESSAGE
  end
end

desc 'clobber generated files'
task :clobber do
  rm_rf "pkg"
end

task :default => :create_app

Something went wrong with that request. Please try again.