class Cucumber::Formatter::NameBuilder

Attributes

name_suffix[R]
row_name[R]
scenario_name[R]

Public Class Methods

new(test_case) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 190
def initialize(test_case)
  @name_suffix = ''
  @row_name = ''
  test_case.describe_source_to self
end

Public Instance Methods

examples_table(*) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 210
def examples_table(*)
  self
end
examples_table_row(row) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 214
def examples_table_row(row)
  @row_name = '| ' + row.values.join(' | ') + ' |'
  @name_suffix = " (outline example : #{@row_name})"
  self
end
feature(*) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 196
def feature(*)
  self
end
scenario(scenario) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 200
def scenario(scenario)
  @scenario_name = (scenario.name.nil? || scenario.name == '') ? 'Unnamed scenario' : scenario.name
  self
end
scenario_outline(outline) click to toggle source
# File lib/cucumber/formatter/junit.rb, line 205
def scenario_outline(outline)
  @scenario_name = (outline.name.nil? || outline.name == '') ? 'Unnamed scenario outline' : outline.name
  self
end