Sha256: 997b273a054f31ee404eac2f0234a2858516a922c341426636f00c3ec72c87e3
Contents?: true
Size: 938 Bytes
Versions: 42
Compression:
Stored size: 938 Bytes
Contents
require 'spec_helper' describe Picky::Sinatra do let(:extendee) { Class.new {} } it 'has no Picky specific methods' do lambda { extendee.indexing }.should raise_error end it 'has no Picky specific methods' do lambda { extendee.searching }.should raise_error end context 'after extending' do before(:each) do extendee.extend Picky::Sinatra end it 'has Picky specific methods' do extendee.send :indexing, some: 'option' end it 'has Picky specific methods' do extendee.send :searching, some: 'option' end it 'gets delegated correctly' do Picky::Tokenizer.should_receive(:default_indexing_with).once.with some: 'option' extendee.send :indexing, some: 'option' end it 'gets delegated correctly' do Picky::Tokenizer.should_receive(:default_searching_with).once.with some: 'option' extendee.send :searching, some: 'option' end end end
Version data entries
42 entries across 42 versions & 1 rubygems