[rspec-users] RSpec seems to be having a hard time loading Helper classes
matt-lists at reprocessed.org
Thu Oct 11 04:46:06 EDT 2007
On 10 Oct 2007, at 22:45, Chris Olsen wrote:
> I am getting the error when I run the command: rake spec
> `load_missing_constant': uninitialized constant ProjectsHelper
> "spec/helpers/projects_helper_spec.rb" "spec/models/project_spec.rb"
> require File.dirname(__FILE__) + '/../spec_helper'
> describe ProjectsHelper do # Helper methods can be called directly in
> the examples (it blocks)
So, it the problem is that the ProjectsHelper constant doesn't exist,
which probably means that app/helpers/projects_helper doesn't exist,
or doesn't declare the ProjectsHelper module.
It could, of course, also be a pluralisation problem, with
ProjectsHelper being called in place of ProjectHelper.
Anyway, whatever it is, you need to make sure that the class/module
name following 'describe' in your helper spec is actually defined
Matt Patterson | Design & Code
<matt at reprocessed org> | http://www.reprocessed.org/
More information about the rspec-users