Class: Mutant::Mutator::Node::Assignment::Variable

Inherits:
Mutant::Mutator::Node::Assignment show all
Defined in:
lib/mutant/mutator/node/assignment.rb

Overview

Abstract base class for variable assignments

Direct Known Subclasses

Class, Global, Instance, Local

Defined Under Namespace

Classes: Class, Global, Instance, Local

Instance Attribute Summary

Attributes inherited from Mutant::Mutator

#input

Instance Method Summary collapse

Methods inherited from Mutant::Mutator::Node

identity

Methods inherited from Mutant::Mutator

each, identity

Instance Method Details

#dispatchundefined

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Emit mutants

Returns:

  • (undefined)


19
20
21
22
23
24
25
# File 'lib/mutant/mutator/node/assignment.rb', line 19

def dispatch
  emit_attribute_mutations(:name) do |mutation|
    mutation.name = "#{self.class::PREFIX}#{mutation.name}".to_sym
    mutation
  end
  emit_attribute_mutations(:value)
end