Re: [rspec-users] have_tag + quantity - question

2009-03-07 Thread MAwiniarski
p, and doesn't require > you to litter your expectations with CSS selectors. > > On Fri, Mar 6, 2009 at 3:40 PM, Stephen Eley wrote: > > On Fri, Mar 6, 2009 at 3:55 AM, David Chelimsky > > wrote: > > > On Thu, Mar 5, 2009 at 7:40 AM, MAwiniarski >

Re: [rspec-users] be_valid (validates_format_of ..., :on => :create)

2009-03-06 Thread MAwiniarski
> FWIW, the OP's code says :on => :create. I also happened to > seehttp://mawiniarski.wordpress.com/2009/02/28/rspec-validation-on-create/, > which reinforced for me that this is about validating on create, not > general validation. I've figured that out after starting a topic. _

[rspec-users] have_tag + quantity - question

2009-03-06 Thread MAwiniarski
Greetings, Is there a way to check quantity of tags? Something like this: response.should have_tag('div').quantity(4) Thanks. ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

[rspec-users] be_valid (validates_format_of ..., :on => :create)

2009-03-01 Thread MAwiniarski
Greetings, How to write Example which will check if model's variable's format is valid using :on => :create, like this: class User < ActiveRecord::Base ... validates_format_of :email, :with => /.../, :on => :create ... Using following code is not right: it "should ..." do @user = users