Flowdock
method

spec_name_for

Importance_0
spec_name_for(file, line_number) public

No documentation

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

Hide source
# File lib/spec/runner/spec_parser.rb, line 11
      def spec_name_for(file, line_number)
        best_match.clear
        file = File.expand_path(file)
        rspec_options.example_groups.each do |example_group|
          consider_example_groups_for_best_match example_group, file, line_number

          example_group.examples.each do |example|
            consider_example_for_best_match example, example_group, file, line_number
          end
        end
        if best_match[:example_group]
          if best_match[:example]
            "#{best_match[:example_group].description} #{best_match[:example].description}"
          else
            best_match[:example_group].description
          end
        else
          nil
        end
      end
Register or log in to add new notes.