class Cucumber::Core::Compiler::TestCaseBuilder

@private

Attributes

receiver[R]

Public Class Methods

new(receiver) click to toggle source
# File lib/cucumber/core/compiler.rb, line 32
def initialize(receiver)
  @receiver = receiver
end

Public Instance Methods

on_background_step(source) click to toggle source
# File lib/cucumber/core/compiler.rb, line 36
def on_background_step(source)
  background_test_steps << Test::Step.new(source)
  self
end
on_step(source) click to toggle source
# File lib/cucumber/core/compiler.rb, line 41
def on_step(source)
  test_steps << Test::Step.new(source)
  self
end
on_test_case(source) click to toggle source
# File lib/cucumber/core/compiler.rb, line 46
def on_test_case(source)
  Test::Case.new(test_steps, source).describe_to(receiver)
  @test_steps = nil
  self
end

Private Instance Methods

background_test_steps() click to toggle source
# File lib/cucumber/core/compiler.rb, line 54
def background_test_steps
  @background_test_steps ||= []
end
test_steps() click to toggle source
# File lib/cucumber/core/compiler.rb, line 58
def test_steps
  @test_steps ||= background_test_steps.dup
end