Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007 21:31:19 -0500, David Chelimsky wrote: > > > > This all may be true but I can't help you diagnose the problem without > > looking at the code. If you'd kindly pastie the spec and model, I'll > > be glad to look at them. Otherwise I

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 21:31:19 -0500, David Chelimsky wrote: > > This all may be true but I can't help you diagnose the problem without > looking at the code. If you'd kindly pastie the spec and model, I'll > be glad to look at them. Otherwise I'm just guessing and that's not > working out to well s

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > Also I really don't think I'm leaking state. I have before(:each) statements > in my "describes" that > basically create new instances of the object as required for that > behavior. So they are fresh each time, correct? Further, even though rails > c

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 19:30:57 -0500, David Chelimsky wrote: >> Removing --reverse makes "rake spec" fail like the other two methods >> now. > > That's what I suspected would happen. > > The reason they were failing differently was that rake was running them > in the opposite order. Removing --rev

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007 18:01:11 -0500, David Chelimsky wrote: > > > One more thing to try. Open up spec/spec.opts and remove the line that > > says "--reverse" if it's there. Then run "rake spec" again and see > > what happens. > > > > Thanks, > > David

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 18:01:11 -0500, David Chelimsky wrote: > One more thing to try. Open up spec/spec.opts and remove the line that > says "--reverse" if it's there. Then run "rake spec" again and see > what happens. > > Thanks, > David Removing --reverse makes "rake spec" fail like the other tw

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007 16:40:11 -0500, David Chelimsky wrote: > > > > Would you please try running it like this: > > > > script/spec spec -b > > > > and this > > > > script/spec spec/models/user_spec.rb -b > > > > and let us know if it's still happening?

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 16:40:11 -0500, David Chelimsky wrote: > > Would you please try running it like this: > > script/spec spec -b > > and this > > script/spec spec/models/user_spec.rb -b > > and let us know if it's still happening? script/spec spec -b changes things. It doesn't give that dupl

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > I'm running through rake(rake spec:models to be exact). The error is: > > 'User should be invalid without a password when creating' FAILED > expected: "can't be blank", > got: ["can't be blank", "can't be blank"] (using ==) > ./spec/models/user_s

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 16:17:53 -0500, David Chelimsky wrote: > Thanks for trying. Sorry it's still a problem. > > How are you running the specs (rake? spec command? textmate?) and what > precisely is the error that you get? Please include a stack trace (not > just one line) > > Thanks, > David I'm

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007 15:41:19 -0500, David Chelimsky wrote: > > > Please update to the latest rspec trunk and try again. I think this is > > due to a bug that was resolved in the 2718 (believe it or not). > > Just updated and am at 2719. The problem st

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 21:12:27 +, Steve wrote: > On Wed, 17 Oct 2007 15:41:19 -0500, David Chelimsky wrote: > >> Please update to the latest rspec trunk and try again. I think this is >> due to a bug that was resolved in the 2718 (believe it or not). > > Just updated and am at 2719. The proble

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 15:41:19 -0500, David Chelimsky wrote: > Please update to the latest rspec trunk and try again. I think this is > due to a bug that was resolved in the 2718 (believe it or not). Just updated and am at 2719. The problem still happens. __

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > On Wed, 17 Oct 2007 15:05:01 -0500, David Chelimsky wrote: > > > Versions? RSpec? Rails? > > > > Details details. :) > > rspec/rspec_on_rails(trunk): r2717 > rails(trunk): r7822 Please update to the latest rspec trunk and try again. I think this is d

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
On Wed, 17 Oct 2007 15:05:01 -0500, David Chelimsky wrote: > Versions? RSpec? Rails? > Details details. :) rspec/rspec_on_rails(trunk): r2717 rails(trunk): r7822 ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/list

Re: [rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread David Chelimsky
Versions? RSpec? Rails? On 10/17/07, Steve <[EMAIL PROTECTED]> wrote: > I had posted this on the regular Rails list, but upon trying this in > script/console, it seems like the behavior only exists when running rspec. > > I'm getting some weird behavior in one of my models. I have a model > define

[rspec-users] rspec causing validates_presence_of to validate twice?

2007-10-17 Thread Steve
I had posted this on the regular Rails list, but upon trying this in script/console, it seems like the behavior only exists when running rspec. I'm getting some weird behavior in one of my models. I have a model defined something like this class User < ActiveRecord::Base attr_accessor :password