Sha256: 7ff8a0d47b67c943b591929c4bae5c51934258149d4182820758c6f555a06c3d
Contents?: true
Size: 913 Bytes
Versions: 7
Compression:
Stored size: 913 Bytes
Contents
require File.expand_path(File.dirname(__FILE__) + "/../../spec_helper") describe "Searchlogic::ActiveRecord::AssociationProxy" do it "should call location conditions" do company = Company.create user = company.users.create(:username => "bjohnson") company.users.send(:username_like, "bjohnson").should == [user] end it "should call ordering conditions" do company = Company.create user = company.users.create(:username => "bjohnson") company.users.send(:ascend_by_username).should == [user] end it "should call 'or' conditions" do company = Company.create user = company.users.create(:username => "bjohnson") company.users.send(:username_or_some_type_id_like, "bjohnson").should == [user] end it "should ignore belongs_to associations" do user = User.create(:male => true) cart = user.carts.create cart.user.send("male").should == true end end
Version data entries
7 entries across 7 versions & 1 rubygems