lib/mutant/subject.rb in mutant-0.8.10 vs lib/mutant/subject.rb in mutant-0.8.11

- old
+ new

@@ -7,14 +7,14 @@ # Mutations for this subject # # @return [Enumerable<Mutation>] # @return [undefined] def mutations - mutations = [neutral_mutation] - Mutator.each(node) do |mutant| - mutations << Mutation::Evil.new(self, wrap_node(mutant)) - end - mutations + [neutral_mutation].concat( + Mutator.mutate(node).map do |mutant| + Mutation::Evil.new(self, wrap_node(mutant)) + end + ) end memoize :mutations # Source path #