Class: Cucumber::Messages::IdGenerator::Incrementing

Inherits:
Object
  • Object
show all
Defined in:
lib/cucumber/messages/id_generator.rb

Instance Method Summary collapse

Constructor Details

#initializeIncrementing

Returns a new instance of Incrementing.


7
8
9
# File 'lib/cucumber/messages/id_generator.rb', line 7

def initialize
  @index = -1
end

Instance Method Details

#new_idObject


11
12
13
14
# File 'lib/cucumber/messages/id_generator.rb', line 11

def new_id
  @index += 1
  @index.to_s
end