class Cucumber::Indent

Public Class Methods

new(node) click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 908
def initialize(node)
  @widths = []
  node.describe_to(self)
end

Public Instance Methods

examples_table(*) click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 926
def examples_table(*); end
examples_table_row(*) click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 927
def examples_table_row(*); end
of(node) click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 929
def of(node)
  # The length of the instantiated steps in --expand mode are currently
  # not included in the calculation of max => make sure to return >= 1
  [1, max - node.to_s.length - node.keyword.length].max
end
record_width_of(node) click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 935
def record_width_of(node)
  @widths << node.keyword.length + node.to_s.length + 1
end

Private Instance Methods

max() click to toggle source
# File lib/cucumber/formatter/legacy_api/adapter.rb, line 941
def max
  @widths.max
end