Sha256: da82ce7b5da30bec3f0c17b21a0fda597d4c2d7f498486a4b6b0f4bea895cf9f
Contents?: true
Size: 695 Bytes
Versions: 1
Compression:
Stored size: 695 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe Optimizer::Relation::Operation::Offset::ZeroOffset, '#optimizable?' do subject { object.optimizable? } let(:base) { Relation.new([ [ :id, Integer ] ], [ [ 1 ] ].each).order } let(:relation) { base.drop(offset) } let(:object) { described_class.new(relation) } before do object.operation.should be_kind_of(Relation::Operation::Offset) end context 'when the operation offset is 0' do let(:offset) { 0 } it { should be(true) } end context 'when the operation offset is not 0' do let(:offset) { 1 } it { should be(false) } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
veritas-optimizer-0.0.4 | spec/unit/veritas/optimizer/relation/operation/offset/zero_offset/optimizable_spec.rb |