Class: CucumberJunitToJson::Models::Rows

Inherits:
Object
  • Object
show all
Defined in:
lib/cucumber_junit_to_json/models/rows.rb

Overview

Abstract representation of a cucumber step table rows attribute

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(cells, line = 0) ⇒ Rows

Returns a new instance of Rows.



10
11
12
13
# File 'lib/cucumber_junit_to_json/models/rows.rb', line 10

def initialize(cells, line = 0)
  @cells = cells
  @line = line
end

Instance Attribute Details

#cellsObject

Returns the value of attribute cells.



9
10
11
# File 'lib/cucumber_junit_to_json/models/rows.rb', line 9

def cells
  @cells
end

#lineObject

Returns the value of attribute line.



9
10
11
# File 'lib/cucumber_junit_to_json/models/rows.rb', line 9

def line
  @line
end

Class Method Details

.parse(data) ⇒ Object



15
16
17
18
19
20
21
# File 'lib/cucumber_junit_to_json/models/rows.rb', line 15

def self.parse(data)
  rows = []
  data.each do |c|
    rows.push(Rows.new(c))
  end
  rows
end