Ticket #482 (closed defect: duplicate)

Opened 10 months ago

Last modified 10 months ago

rake spec is broken

Reported by: flazzari..@gmail.com Assigned to:
Priority: major Milestone: The Future
Component: Rspec Harness Keywords: rspec spec rake
Cc:

Description

there is no dir spec/merb in my merb project.

unless i'm using this wrong i believe it to be broken.

% rake spec TASK=foo          
(in /Users/franco/Desktop/pkg_track/server)
Connecting to database...
/Library/Ruby/Gems/1.8/gems/rspec-1.1.2/lib/spec/runner/options.rb:216:in `files_to_load': File or directory not found: spec/merb/foo_spec.rb (RuntimeError)
	from /Library/Ruby/Gems/1.8/gems/rspec-1.1.2/lib/spec/runner/options.rb:210:in `each'
	from /Library/Ruby/Gems/1.8/gems/rspec-1.1.2/lib/spec/runner/options.rb:210:in `files_to_load'
	from /Library/Ruby/Gems/1.8/gems/rspec-1.1.2/lib/spec/runner/options.rb:83:in `run_examples'
	from /Library/Ruby/Gems/1.8/gems/rspec-1.1.2/lib/spec/runner/command_line.rb:19:in `run'
	from /Library/Ruby/Gems/1.8/gems/rspec-1.1.2/bin/spec:4
rake aborted!
Command ruby -I"lib:server/lib" "/Library/Ruby/Gems/1.8/gems/rspec-1.1.2/bin/spec" "spec/merb/foo_spec.rb" --format specdoc --colour failed

(See full trace by running task with --trace)

Change History

01/26/08 08:08:35 changed by flazzari..@gmail.com

this fixes it.

diff --git a/server/Rakefile b/server/Rakefile
index ca6a9aa..77fc10f 100644
--- a/server/Rakefile
+++ b/server/Rakefil..@@ -77,7 +77,7 @@ desc "Run a specific spec with TASK=xxxx"
 Spec::Rake::SpecTask.new('spec') do |t|
   t.spec_opts = ["--format", "specdoc", "--colour"]
   t.libs = ['lib', 'server/lib' ]
-  t.spec_files = ["spec/merb/#{ENV['TASK']}_spec.rb"]
+  t.spec_files = ["spec/#{ENV['TASK']}_spec.rb"]
 end
 
 desc "Run all specs output html"

you can run a specific patch with:

# will run spec/models/foo_spec.rb
% rake spec TASK=models/foo

02/11/08 13:32:02 changed by shayarne..@gmail.com

  • status changed from new to closed.
  • resolution set to duplicate.