Sha256: 00cd7107bbcbae9b3dc0522d36c4230646ac3c370920e27d024e3f308bf16fa7

Contents?: true

Size: 639 Bytes

Versions: 1

Compression:

Stored size: 639 Bytes

Contents

require 'compiler_helper'
module Alf
  class Compiler
    describe Default, "extend" do

      subject{
        compiler.call(expr)
      }

      let(:expr){
        extend(an_operand(leaf), computation)
      }

      let(:computation){
        TupleComputation[{ foo: "12" }]
      }

      it_should_behave_like "a traceable compiled"

      it 'has a SetAttr cog' do
        subject.should be_a(Engine::SetAttr)
      end

      it 'has the correct computation' do
        subject.computation.should be(computation)
      end

      it 'has the correct sub-cog' do
        subject.operand.should be(leaf)
      end

    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
alf-core-0.15.0 spec/unit/alf-compiler/default/test_extend.rb