Sha256: 0d092372f3d9ac31952084dcb4be1b36fb9fec5638ee6e34b7b862a15b4b3e2b
Contents?: true
Size: 623 Bytes
Versions: 19
Compression:
Stored size: 623 Bytes
Contents
require 'spec_helper' module Finitio describe SeqType, "equality" do let(:type) { SeqType.new(intType) } let(:type2){ SeqType.new(intType) } let(:type3){ SeqType.new(floatType) } it 'should apply structural equality' do expect(type == type2).to eq(true) end it 'should apply distinguish different types' do expect(type == type3).to eq(false) end it 'should be a total function, with false for non types' do expect(type == 12).to eq(false) end it 'should implement hash accordingly' do expect(type.hash == type2.hash).to eq(true) end end end
Version data entries
19 entries across 19 versions & 1 rubygems