myronmarston/vcr — Issue #113: undefined method `configure' for VCR:Module
Author: gavinlaking
Created: 2011-12-04 12:11:41+00:00
State: open

Hi Myron/all,

I've recently been trying out VCR with a few of my projects and all is well when I'm using Rails too. However, I've just started a really simple project (https://github.com/gavinlaking/coop_bsp) in Sinatra. I've included VCR and require the configuration, however, running RSpec gives me the following stacktrace:

Chadbook:coop_bsp gavinlaking$ rspec
/Users/gavinlaking/Sites/coop_bsp/spec/support/vcr.rb:1:in `': undefined method `configure' for VCR:Module (NoMethodError)
from /Users/gavinlaking/Sites/coop_bsp/spec/spec_helper.rb:11:in `require'
from /Users/gavinlaking/Sites/coop_bsp/spec/spec_helper.rb:11:in `'
from /Users/gavinlaking/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /Users/gavinlaking/.rvm/rubies/ruby-1.9.2-p290/lib/ruby/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
from /Users/gavinlaking/Sites/coop_bsp/spec/coop_bsp_spec.rb:1:in `'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/configuration.rb:459:in `load'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/configuration.rb:459:in `block in load_spec_files'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/configuration.rb:459:in `map'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/configuration.rb:459:in `load_spec_files'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/command_line.rb:18:in `run'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/runner.rb:80:in `run_in_process'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/runner.rb:69:in `run'
from /Users/gavinlaking/.rvm/gems/ruby-1.9.2-p290@coop_bsp/gems/rspec-core-2.7.1/lib/rspec/core/runner.rb:10:in `block in autorun'

I've tried putting the configuration inline, and reordering the require statements to no avail. I'm not sure if I've encountered a bona-fide bug or a simple configuration error on my behalf. Any ideas?

Thanks for your time!

Gav