Sha256: f86c97a5c844353d1d7e93589387f800d598cc590f50e3ca7b1472e4c773f9d7

Contents?: true

Size: 577 Bytes

Versions: 3

Compression:

Stored size: 577 Bytes

Contents

require 'spec_helper'

describe Itiel::Script::ChainedStep do
  before :each do
    klass = Class.new
    klass.send :include, Itiel::Script::ChainedStep

    @step = klass.new
  end

  describe :input= do
    before :each do
      @input_stream = double
      allow(@step).to receive(:next_step).and_return double
    end

    it "executes with input stream, sets output as next_step input" do
      allow(@step).to receive(:execute).with(@input_stream)
      allow(@step.next_step).to receive(:input=).with(@input_stream)
      @step.input = @input_stream
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
itiel-0.1.2 spec/script/chained_step_spec.rb
itiel-0.1.1 spec/script/chained_step_spec.rb
itiel-0.1.0 spec/script/chained_step_spec.rb