Sha256: c1374a692745eaecb172e683f68e78889a6ed99a350542b5dd467241a06252c8

Contents?: true

Size: 600 Bytes

Versions: 1

Compression:

Stored size: 600 Bytes

Contents

# encoding: utf-8

require 'spec_helper'
require File.expand_path('../fixtures/classes', __FILE__)

describe Function::Unary, '#hash' do
  subject { object.hash }

  let(:described_class) { UnarySpecs::Object                     }
  let(:attribute)       { Attribute::Integer.new(:id)            }
  let(:header)          { Relation::Header.coerce([ attribute ]) }
  let(:operand)         { attribute.eq(1)                        }
  let(:object)          { described_class.new(operand)           }

  it_should_behave_like 'a hash method'

  it { should == described_class.hash ^ operand.hash }
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
axiom-0.1.0 spec/unit/axiom/function/unary/hash_spec.rb