Quoting Jeffrey L. Taylor <[EMAIL PROTECTED]>: > > I've found a conflict between assert2 and ActiveSupport. Both define the > method in_groups_of() with different signatures and semantics. It shows up in > Ultrasphinx when I run my tests. I've reproduced it in the console, see > below. Any suggests on how to force the desired in_groups_of() method? > > TIA, > Jeffrey > > > script/console > Loading development environment (Rails 2.1.2) > >> a = [1, 2, 3, 4] > => [1, 2, 3, 4] > >> a.in_groups_of(2) > => [[1, 2], [3, 4]] > >> require 'assert2' > => ["Assert_2_0"] > >> a.in_groups_of(2) > LocalJumpError: no block given > from /usr/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:27:in > `each_slice' > from > /usr/lib/ruby/gems/1.8/gems/assert2-0.3.1/lib/ruby_reflector.rb:829:in `each' > from > /usr/lib/ruby/gems/1.8/gems/assert2-0.3.1/lib/ruby_reflector.rb:829:in > `each_slice' > from > /usr/lib/ruby/gems/1.8/gems/assert2-0.3.1/lib/ruby_reflector.rb:829:in > `in_groups_of' > from (irb):4 > >> quit
My solution is to delete the in_groups_of method in the assert{2.0}. It appears to be just a special case of the code in ActiveSupport. Jeffrey --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en -~----------~----~----~----~------~----~------~--~---