Sha256: b9c4bf65e5e082c1712f9bd6da296a201ae35f6f40406376c52a3620cf2f56d3

Contents?: true

Size: 484 Bytes

Versions: 1

Compression:

Stored size: 484 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Aggregate::Sum, '#type' do
  subject { object.type }

  let(:object)  { described_class.new(operand) }
  let(:operand) { mock('Unhandled')            }

  before do
    operand.stub(:freeze => operand, :frozen? => true)
  end

  it 'delegates to Attribute.infer_type' do
    return_value = mock('Return Value')
    Attribute.should_receive(:infer_type).with(operand).and_return(return_value)
    should equal(return_value)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
axiom-0.1.0 spec/unit/axiom/aggregate/sum/type_spec.rb