[Ruby] matching spaces as \s+ in assert_select

Mikhail Seregine seregine at yahoo.com
Thu Dec 6 12:20:01 PST 2007


OK, enlighten me, why the '\s+'? Why not:

assert_select 'h3', Regexp.new("Wants to do 1 thing".gsub!(/\s+/, ' '))
On Dec 6, 2007, at 11:23 AM, Laurel Fan wrote:

> On Dec 5, 2007 10:52 AM, Laurel Fan <laurel.fan at gmail.com> wrote:
>>     assert_select 'h3', Regexp.new("Wants to do 1 thing".gsub!(/\s 
>> +/, '\s+'))
>
> Oh yeah, I totally don't want a ! in there...
>
>
> -- 
> Laurel Fan
> http://blog.gorgorg.org
> _______________________________________________
> Ruby at zenspider.com - Seattle.rb non-commercial list
> http://www.zenspider.com/seattle.rb
> http://www.zenspider.com/mailman/listinfo/ruby



More information about the Ruby mailing list