Class/Module Index [+]

Quicksearch

Cucumber::RbSupport::RbWorld

All steps are run in the context of an object that extends this module.

Attributes

__cucumber_step_mother[W]
__natural_language[W]

Public Class Methods

alias_adverb(adverb) click to toggle source
# File lib/cucumber/rb_support/rb_world.rb, line 6
def alias_adverb(adverb)
  alias_method adverb, :__cucumber_invoke
end

Public Instance Methods

Transform(arg) click to toggle source

Call a Transform with a string from another Transform definition

# File lib/cucumber/rb_support/rb_world.rb, line 12
def Transform(arg)
  rb = @__cucumber_step_mother.load_programming_language('rb')
  rb.execute_transforms([arg]).first
end
announce(announcement) click to toggle source

See StepMother#announce

# File lib/cucumber/rb_support/rb_world.rb, line 41
def announce(announcement)
  @__cucumber_step_mother.announce(announcement)
end
announce_world() click to toggle source

Prints out the world class, followed by all included modules.

# File lib/cucumber/rb_support/rb_world.rb, line 56
def announce_world
  announce "WORLD:\n  #{self.class}"
  world = self
  (class << self; self; end).instance_eval do
    world.announce "  #{included_modules.join("\n  ")}"
  end
end
ask(question, timeout_seconds=60) click to toggle source

See StepMother#ask

# File lib/cucumber/rb_support/rb_world.rb, line 46
def ask(question, timeout_seconds=60)
  @__cucumber_step_mother.ask(question, timeout_seconds)
end
embed(file, mime_type) click to toggle source

See StepMother#embed

# File lib/cucumber/rb_support/rb_world.rb, line 51
def embed(file, mime_type)
  @__cucumber_step_mother.embed(file, mime_type)
end
pending(message = "TODO") click to toggle source

Mark the matched step as pending.

# File lib/cucumber/rb_support/rb_world.rb, line 65
def pending(message = "TODO")
  if block_given?
    begin
      yield
    rescue Exception => e
      raise Pending.new(message)
    end
    raise Pending.new("Expected pending '#{message}' to fail. No Error was raised. No longer pending?")
  else
    raise Pending.new(message)
  end
end
py_string(string_with_triple_quotes, file=nil, line_offset=0) click to toggle source

See StepMother#py_string

# File lib/cucumber/rb_support/rb_world.rb, line 36
def py_string(string_with_triple_quotes, file=nil, line_offset=0)
  @__cucumber_step_mother.py_string(string_with_triple_quotes, file, line_offset)
end
steps(steps_text) click to toggle source

See StepMother#invoke_steps

# File lib/cucumber/rb_support/rb_world.rb, line 26
def steps(steps_text)
  @__cucumber_step_mother.invoke_steps(steps_text, @__natural_language)
end
table(text_or_table, file=nil, line_offset=0) click to toggle source

See StepMother#table

# File lib/cucumber/rb_support/rb_world.rb, line 31
def table(text_or_table, file=nil, line_offset=0)
  @__cucumber_step_mother.table(text_or_table, file, line_offset)
end

[Validate]

Generated with the Darkfish Rdoc Generator 2.