spec/unit/veritas/optimizer/algebra/restriction/tautology/optimize_spec.rb in veritas-optimizer-0.0.3 vs spec/unit/veritas/optimizer/algebra/restriction/tautology/optimize_spec.rb in veritas-optimizer-0.0.4
- old
+ new
@@ -1,13 +1,15 @@
+# encoding: utf-8
+
require 'spec_helper'
describe Optimizer::Algebra::Restriction::Tautology, '#optimize' do
subject { object.optimize }
let(:header) { Relation::Header.new([ [ :id, Integer ] ]) }
let(:base) { Relation.new(header, [ [ 1 ] ].each) }
- let(:predicate) { Logic::Proposition::Tautology.instance }
- let(:relation) { base.restrict(predicate) }
+ let(:predicate) { Function::Proposition::Tautology.instance }
+ let(:relation) { base.restrict { predicate } }
let(:object) { described_class.new(relation) }
before do
object.should be_optimizable
end