Re: [rspec-users] Controller Specs - undefined local variable or method 'app'

2011-02-12 Thread Doug Bryant
Your hunch looks correct - I ran it through the debugger last night and found the spot where it was failing in rack-test although I don't know why it was failing. I removed this line from my spec_helper.rb: > config.include Rack::Test::Methods and it magically started working again. Thanks for

Re: [rspec-users] using before(:all) for cheap benchmark?

2011-02-12 Thread David Chelimsky
On Feb 9, 2011, at 9:36 PM, Robert Poor wrote: > I'm a new (and complete) convert to RSpec, especially when coupled with > autotest. > > I notice when automate processes my entire spec directory it takes about > eight minutes. I have many more tests to add before I'm done, so eventually > I'l

Re: [rspec-users] hash form of stub_chain returning nil for chains with shared first message

2011-02-12 Thread David Chelimsky
On Feb 12, 2011, at 5:55 PM, David Chelimsky wrote: > > On Feb 11, 2011, at 7:51 AM, Frederick Cheung wrote: > >> On Feb 10, 7:30 pm, David Chelimsky wrote: >>> On Feb 10, 2011, at 12:40 PM, Frederick Cheung wrote: >>> I'm new using rspec, so please forgive me if I'm barking up the wrong

Re: [rspec-users] Controller Specs - undefined local variable or method 'app'

2011-02-12 Thread James Martin
Not 100% sure, but that failure looks suspiciously like something you get when using rack-test; which expects an 'app' method to be defined that returns an instance of your rack-compatible application. On Saturday, February 12, 2011, Doug Bryant wrote: > On one of my projects using rspec 2.5 & ra

Re: [rspec-users] hash form of stub_chain returning nil for chains with shared first message

2011-02-12 Thread David Chelimsky
On Feb 11, 2011, at 7:51 AM, Frederick Cheung wrote: > On Feb 10, 7:30 pm, David Chelimsky wrote: >> On Feb 10, 2011, at 12:40 PM, Frederick Cheung wrote: >> >>> I'm new using rspec, so please forgive me if I'm barking up the wrong tree, >>> but... >> >>> I'd expect this to pass (using rspec

[rspec-users] Control order of spec files for an integration test?

2011-02-12 Thread Wolfram Arnold, RubyFocus
Hi, I'm using RSpec2 with Capybara and Celerity for an integration test. I'd like to use some of the tests (e.g. user registration) to run as a prerequisite to other steps. I was hoping that by naming files in the correct alphabetical order, RSpec would run them in alphabetical order. RSpec 1.x

[rspec-users] using before(:all) for cheap benchmark?

2011-02-12 Thread Robert Poor
I'm a new (and complete) convert to RSpec, especially when coupled with autotest. I notice when automate processes my entire spec directory it takes about eight minutes. I have many more tests to add before I'm done, so eventually I'll want to streamline my tests. Is there a quick and dirty way

Re: [rspec-users] mocking an AR: ActiveRecord::AssociationTypeMismatch error

2011-02-12 Thread Fearless Fool
David Chelimsky wrote in post #981239: > http://relishapp.com/rspec/rspec-rails/v/2-5/dir/mocks/mock-model > HTH, > David Boy howdy, TH to the max. (How did I miss that???) Thanks. - ff -- Posted via http://www.ruby-forum.com/. ___ rspec-users maili

Re: [rspec-users] Problem with rendering JSON

2011-02-12 Thread Ants Pants
On 11 February 2011 23:45, Matt Wynne wrote: > > On 11 Feb 2011, at 16:04, Ants Pants wrote: > > You are my last resort for solving this issue as I have tried and tried to > solve it myself but can't. > > I'm not even sure if it's an RSpec issue but the thing is, if I run the > request from the b