class Rubycritic::SmellAdapter::Reek
def create_smell(smell)
def create_smell(smell) locations = smell_locations(smell.source, smell.lines) message = smell.message context = smell.context type = smell.subclass Smell.new(:locations => locations, :context => context, :message => message, :type => type) end
def initialize(reek)
def initialize(reek) @reek = reek end
def smell_locations(file_path, file_lines)
def smell_locations(file_path, file_lines) file_lines.uniq.map do |file_line| Location.new(file_path, file_line) end end
def smells
def smells @reek.smells.map do |smell| create_smell(smell) end end