Flowdock
method

print_step

Importance_0
print_step(klass, type, description, *args) public

No documentation

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

Hide source
# File lib/spec/runner/formatter/story/html_formatter.rb, line 159
          def print_step(klass, type, description, *args)
            spans = args.map { |arg| "<span class=\"param\">#{arg}</span>" }
            desc_string = description.step_name
            arg_regexp = description.arg_regexp           
            inner = if(type == @previous_type)
              "And "
            else
              "#{type.to_s.capitalize} "
            end
            i = -1
            inner += desc_string.gsub(arg_regexp) { |param| spans[i+=1] }
            
            @scenario_text += "                  <li class=\"#{klass}\">#{inner}</li>\n"
            
            if type == 'given scenario''given scenario'
              @previous_type = :given
            else
              @previous_type = type
            end
            
          end
Register or log in to add new notes.