Sha256: 6df0787a87acb8f2be221a69744fed77c8479f03fc86f5a586b61f32542fc9bf

Contents?: true

Size: 599 Bytes

Versions: 2

Compression:

Stored size: 599 Bytes

Contents

require 'spec_helper'
module Alf
  module Algebra
    describe Page do

      let(:operator_class){ Page }

      it_should_behave_like("An operator class")

      subject{
        a_lispy.page(an_operand, [[:name, :asc]], 2)
      }

      it { should be_a(Page) }

      it 'should have correct ordering' do
        subject.ordering.should eq(Ordering.coerce([[:name, :asc]]))
      end

      it 'should have correct page index' do
        subject.page_index.should eq(2)
      end

      it 'should have default page size' do
        subject.page_size.should eq(25)
      end

    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
alf-core-0.15.0 spec/unit/alf-algebra/operator/test_page.rb
alf-core-0.14.0 spec/unit/alf-algebra/operator/test_page.rb