method

difference_between_arrays

Importance_0
RSpec latest stable (1.3.1) - 0 notes - Class: Spec::Matchers::MatchArray
difference_between_arrays(array_1, array_2) private

No documentation

This method has no description. You can help the RSpec community by adding new notes.

Hide source
# File lib/spec/matchers/match_array.rb, line 40
        def difference_between_arrays(array_1, array_2)
          difference = array_1.dup
          array_2.each do |element|
            if index = difference.index(element)
              difference.delete_at(index)
            end
          end
          difference
        end
Register or log in to add new notes.