Sha256: 21383ffcfbf6eba9bd108bee73df70455f1e6bafd988ca0bf2091eeccf6c0873
Contents?: true
Size: 823 Bytes
Versions: 1
Compression:
Stored size: 823 Bytes
Contents
require 'spec_helper' describe 'Collection' do it 'should return results for a single child hash' do results = ARBookFinder.collection('Awards' => 'ALA Notable/Best Books') results.books.size.should > 0 end it 'should return results for a multi child hash' do results = ARBookFinder.collection('State Lists' => { 'Indiana' => 'IN Young Hoosier Middle Grades Book Award Nominees 2013-2014' }) results.books.size.should > 0 end it 'should return results for page 2' do results = ARBookFinder.collection({ 'Awards' => 'ALA Notable/Best Books' }, 2) results.current_page.should == 2 end it 'should fetch book data' do results = ARBookFinder.collection('Awards' => 'ALA Notable/Best Books') book = results.books[0] book.fetch book.title.should_not be '' end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
ar_book_finder-1.1.0 | spec/ar_book_finder/collection_spec.rb |