Sha256: cf22362d23c0471ee2944967ca43f2d38ffd0734e685c92f367a84103b271de0

Contents?: true

Size: 687 Bytes

Versions: 2

Compression:

Stored size: 687 Bytes

Contents

require 'spec_helper'
module Gisele::Language::Syntax
  describe EventSet, "to_ast" do

    it 'converts empty lists as expected' do
      expr     = '{ }'
      expected = [:event_set]
      ast(expr, :event_set).should eq(expected)
    end

    it 'converts singleton lists as expected' do
      expr     = '{Diagnosis:start}'
      expected = [:event_set, "Diagnosis:start"]
      ast(expr, :event_set).should eq(expected)
    end

    it 'converts non empty lists as expected' do
      expr     = '{Diagnosis:start, an_event, another_one}'
      expected = [:event_set, "Diagnosis:start", "an_event", "another_one"]
      ast(expr, :event_set).should eq(expected)
    end

  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
gisele-0.4.0 spec/unit/language/syntax/to_ast/test_event_set.rb
gisele-0.3.0 spec/unit/language/syntax/to_ast/test_event_set.rb