Sha256: 481ef860142e1d43d02c3a5ae0c5f5bb29b4fe8c81fa577c9515ac3b4752746f

Contents?: true

Size: 529 Bytes

Versions: 1

Compression:

Stored size: 529 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Chain::Outgoing, '#call' do

  subject { object.call(request) }

  let(:object) {
    Class.new {
      include Substation::Chain::Outgoing
      def call(request)
        response = request.success(request.input)
        respond_with(response, :altered)
      end
    }.new
  }

  let(:response) { Response::Success.new(request, :altered) }
  let(:request)  { Request.new(env, input) }
  let(:env)      { double }
  let(:input)    { double }

  it { should eql(response) }
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
substation-0.0.10.beta2 spec/unit/substation/chain/outgoing/call_spec.rb