Sha256: 130e9700d14bebce7f66f3ae3d4e5944d213b559dcfa94b5171e5a11e231fb8a

Contents?: true

Size: 491 Bytes

Versions: 5

Compression:

Stored size: 491 Bytes

Contents

# encoding: utf-8

require 'spec_helper'

describe Operation::Binary, '#hash' do
  subject { object.hash }

  let(:described_class) { Class.new { include Operation::Binary } }
  let(:left)            { mock('Left').freeze                     }
  let(:right)           { mock('Right').freeze                    }
  let(:object)          { described_class.new(left, right)        }

  it_should_behave_like 'a hash method'

  it { should == described_class.hash ^ left.hash ^ right.hash }
end

Version data entries

5 entries across 5 versions & 2 rubygems

Version Path
axiom-0.1.0 spec/unit/axiom/operation/binary/hash_spec.rb
veritas-0.0.7 spec/unit/veritas/operation/binary/hash_spec.rb
veritas-0.0.6 spec/unit/veritas/operation/binary/hash_spec.rb
veritas-0.0.5 spec/unit/veritas/operation/binary/hash_spec.rb
veritas-0.0.4 spec/unit/veritas/operation/binary/hash_spec.rb