Class: Cucumber::Ast::Table

Inherits:
Object
  • Object
show all
Defined in:
lib/cuke4duke/table_ext.rb

Instance Method Summary collapse

Instance Method Details

#diffHashes(map_list, options = {}) ⇒ Object



10
11
12
# File 'lib/cuke4duke/table_ext.rb', line 10

def diffHashes(map_list, options={})
  diff!(maps_to_hashes(map_list), opts(options))
end

#diffLists(list_list, options = {}) ⇒ Object



6
7
8
# File 'lib/cuke4duke/table_ext.rb', line 6

def diffLists(list_list, options={})
  diff!(lists_to_arrays(list_list), opts(options))
end

#mapColumn(column, converter) ⇒ Object



14
15
16
# File 'lib/cuke4duke/table_ext.rb', line 14

def mapColumn(column, converter)
  map_column!(column) { |cellValue| converter.convertCell(cellValue) }
end

#mapHeaders(mappings) ⇒ Object



18
19
20
# File 'lib/cuke4duke/table_ext.rb', line 18

def mapHeaders(mappings)
  map_headers!(Hash[mappings.entrySet.map{|e| [e.key, e.value]}])
end