class RSpecItHandler

Handler that will set up the method <-> example map

Public Instance Methods

process() click to toggle source
# File lib/yard-examples-from-rspec.rb, line 19
def process
  param = statement.parameters.first.jump(:string_content).source
  if param =~ Regexp.union(*EXAMPLE_MATCHERS)
    RSpecExampleRegistry.example_map[RSpecDescribeHandler.current_path] =  statement.last.last.source.gsub("\n      ","\n")
  end
end