Sha256: ed1eadf95d22a8c911d9d09c316eaa23610c8b3f9996d33e6a23d7b72a37a45a
Contents?: true
Size: 694 Bytes
Versions: 1
Compression:
Stored size: 694 Bytes
Contents
# encoding: utf-8 require 'spec_helper' [ :intersect, :& ].each do |method| describe Algebra::Intersection::Methods, "##{method}" do subject { object.send(method, other) } let(:described_class) { Relation } let(:header) { [ [ :id, Integer ] ] } let(:object) { described_class.new(header, LazyEnumerable.new([ [ 1 ] ])) } let(:other) { described_class.new(header, LazyEnumerable.new([ [ 2 ] ])) } it { should be_instance_of(Algebra::Intersection) } it 'behaves the same as Array#&' do should == object.to_a & other.to_a end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
axiom-0.1.0 | spec/unit/axiom/algebra/intersection/methods/intersect_spec.rb |