schleyfox/peach — pull request #5 by magnusmorton (2012-05-07 12:25:00+00:00)
Title: Monkey-patches Enumberable: fixes issue #4

Have modified peach.rb to remove calls to slice and count, and modify the code so it works with `Enumerable`. Rather than get `Array` to include the module, peach.rb now opens `Enumerable` directly and defines the methods (I tried doing `Enumerable.send(:include, Peach)` but that only worked if `peach` was `require`'d from within the same directory it was located in). This fixes issue #4.

When I rewrote `#pselect` to work with `Enumerable`, I no longer needed to use `divvy`, so I removed that and its tests also, though all the methods do the same thing when calculating the chunk size, so a similar method might be extracted out to DRY up the code somewhat.