Sha256: b6cae439a07ecfbc9f1c4f78d2083cea02766d6d5a51c70d1775682d6c0a1291

Contents?: true

Size: 694 Bytes

Versions: 6

Compression:

Stored size: 694 Bytes

Contents

# The only test definitions that should go in here are those that
# will build sequence steps. Meaning, each test step here is meant
# to be one that is equivalent to a sequence of test steps.

Given(/^the step "(?:Given|When|Then|\*) \[((?:[^\\\]]|\\.)+)\](:?)" is defined to mean:$/) do |phrase, table, sequence|
  data_provided = (table == ':')
  add_sequence(phrase, sequence, data_provided)
end

When(/^\[((?:[^\\\]]|\\.)+)\]$/) do |phrase|
  invoke_sequence(phrase)
end

When(/^\[([^\]]+)\]:$/) do |phrase, data_table|
  unless data_table.kind_of?(Lucid::AST::Table)
    raise Sequence::DataTableNotFound.new(phrase)
  end

  invoke_sequence(phrase, data_table.raw)
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
lucid-0.4.1 lib/lucid/sequence/sequence_steps.rb
lucid-0.4.0 lib/lucid/sequence/sequence_steps.rb
lucid-0.3.3 lib/lucid/sequence/sequence_steps.rb
lucid-0.3.0 lib/lucid/sequence/sequence_steps.rb
lucid-0.2.1 lib/lucid/sequence/sequence_steps.rb
lucid-0.2.0 lib/lucid/sequence/sequence_steps.rb