Sha256: cb69d7922af205d8e2e9ea27baf51b08dd8b38708746aa35d9fb5b6a3a0f31e7
Contents?: true
Size: 553 Bytes
Versions: 1
Compression:
Stored size: 553 Bytes
Contents
# encoding: utf-8 require 'spec_helper' describe Optimizer::Function::Util, '.max' do subject { object.max(operand) } let(:object) { Optimizer::Function::Util } context 'with an Integer attribute' do let(:operand) { Attribute::Integer.new(:id, size: 1..10) } it { should == 10 } end context 'with a String attribute' do let(:operand) { Attribute::String.new(:id, minimum_length: 1, maximum_length: 10) } it { should == 10 } end context 'with a constant' do let(:operand) { 1 } it { should == 1 } end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
axiom-optimizer-0.2.0 | spec/unit/axiom/optimizer/function/util/class_methods/max_spec.rb |