Sha256: ba4d6e953b27e2f0d06172542c0197fed1c8124588644ca90ca801eb0e127cae
Contents?: true
Size: 577 Bytes
Versions: 15
Compression:
Stored size: 577 Bytes
Contents
require File.expand_path(File.join(File.dirname(__FILE__), 'spec_helper')) require 'algolia/webmock' describe 'With a mocked client' do before(:each) do WebMock.enable! Thread.current[:algolia_hosts] = nil # reset session objects end it "should add a simple object" do index = Algolia::Index.new("friends") index.add_object!({ :name => "John Doe", :email => "john@doe.org" }) index.search('').should == {} # mocked index.list_user_keys index.browse index.clear index.delete end after(:each) do WebMock.disable! end end
Version data entries
15 entries across 15 versions & 1 rubygems