padrino-framework: Padrino has a problem with Rake when using RSpec
Hi. I’m enjoying my development with Padrino thank you.
Using RSpec as testing framework, rake command (not “padrino rake”) seems to have a problem. And it causes “heroku rake” failure.
I’m using below.
- Padrino 0.9.26
- Ruby 1.9.2 p188
- MacOSX (Snow Leopard).
Appears by the following.
$ padrino g project test-project -t rspec -b
$ cd test-project
Save below as “Rakefile”.
require File.dirname(__FILE__) + '/config/boot.rb'
require 'thor'
require 'padrino-core/cli/rake'
PadrinoTasks.init
padrino rake
$ padrino rake -T
=> Executing Rake -T ...
rake routes[query] # Displays a listing of the named routes within a project, optionally only those matched by [query]
rake routes:app[app] # Displays a listing of the named routes a given app [app]
rake secret # Generate a secret key
rake seed # Load the seed data from db/seeds.rb
rake spec # Run complete application spec suite
Normal rake
$ rake -T
(in /Users/yuya/dev/ruby/test-project)
=> Located unlocked Gemfile for development
rake aborted!
no such file to load -- rspec/core/rake_task
/Users/yuya/.rvm/gems/ruby-1.9.2-head/gems/padrino-core-0.9.26/lib/padrino-core/cli/rake.rb:21:in `load'
(See full trace by running task with --trace)
About this issue
- Original URL
- State: closed
- Created 13 years ago
- Comments: 15 (12 by maintainers)
Quick fix for deploying to heroku:
spec/spec.rake
Could the rake tasks in spec/ and test/ be ignored unless env is test?