[rspec-users] rspec rake tasks fail inside active record
David Chelimsky
dchelimsky at gmail.com
Tue Jul 6 09:02:33 EDT 2010
On Jul 6, 2010, at 6:49 AM, andreyr wrote:
> Hi,
>
> i have a problem that any of my rspec rake tasks fail with the following
> error:
> rake -f unittests.rake spec
> ** Invoke spec (first_time)
> ** Execute spec
> C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support/core_ext/logger.rb:53:
> undefined method `datetime_format=' for class `Logger' (NameError)
> from
> C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
> `gem_original_require'
> from
> C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support/core_ext.rb:8
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support/core_ext.rb:8:in
> `each'
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support/core_ext.rb:8
> from
> C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in
> `gem_original_require'
> from
> C:/Ruby18/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:31:in `require'
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/activesupport-2.3.8/lib/active_support.rb:56
> ... 11 levels...
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/example_group_runner.rb:14:in
> `load_file
> s'
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/options.rb:133:in
> `run_examples'
> from
> C:/Ruby18/lib/ruby/gems/1.8/gems/rspec-1.3.0/lib/spec/runner/command_line.rb:9:in
> `run'
> from C:/Ruby18/lib/ruby/gems/1.8/gems/rspec-1.3.0/bin/spec:5
> rake aborted!
>
> My rake tasks are trivial like this:
> Spec::Rake::SpecTask.new do |t|
> t.spec_files = FileList['lib/deposit_handler/spec/*.rb']
> end
>
> I am watir+rspec. Could the problem be that activesupport being a part of
> rails is missing some dependencies? Googling around did not seem to bring
> any results.
We need to see some code. Please post the Rakefile and spec file.
More information about the rspec-users
mailing list