searchlogic 2.4.23 → 2.4.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/VERSION.yml +1 -1
- data/lib/searchlogic/search.rb +4 -0
- data/searchlogic.gemspec +2 -2
- data/spec/searchlogic/search_spec.rb +8 -0
- metadata +4 -4
data/VERSION.yml
CHANGED
data/lib/searchlogic/search.rb
CHANGED
@@ -106,6 +106,10 @@ module Searchlogic
|
|
106
106
|
order && order.to_s.gsub(/^(ascend|descend)_by_/, '')
|
107
107
|
end
|
108
108
|
|
109
|
+
def respond_to?(*args)
|
110
|
+
super || scope?(args.first)
|
111
|
+
end
|
112
|
+
|
109
113
|
private
|
110
114
|
def method_missing(name, *args, &block)
|
111
115
|
condition_name = condition_name(name)
|
data/searchlogic.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{searchlogic}
|
8
|
-
s.version = "2.4.
|
8
|
+
s.version = "2.4.24"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Ben Johnson of Binary Logic"]
|
12
|
-
s.date = %q{2010-08-
|
12
|
+
s.date = %q{2010-08-22}
|
13
13
|
s.description = %q{Searchlogic makes using ActiveRecord named scopes easier and less repetitive.}
|
14
14
|
s.email = %q{bjohnson@binarylogic.com}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -421,6 +421,14 @@ describe Searchlogic::Search do
|
|
421
421
|
end
|
422
422
|
end
|
423
423
|
|
424
|
+
context "#respond_to?" do
|
425
|
+
it "should respond to created_at_lte" do
|
426
|
+
s = User.search
|
427
|
+
s.created_at_lte
|
428
|
+
s.respond_to?(:created_at_lte).should == true
|
429
|
+
end
|
430
|
+
end
|
431
|
+
|
424
432
|
context "delegation" do
|
425
433
|
it "should return all when not given any conditions" do
|
426
434
|
3.times { User.create }
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: searchlogic
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 47
|
5
5
|
prerelease: false
|
6
6
|
segments:
|
7
7
|
- 2
|
8
8
|
- 4
|
9
|
-
-
|
10
|
-
version: 2.4.
|
9
|
+
- 24
|
10
|
+
version: 2.4.24
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Ben Johnson of Binary Logic
|
@@ -15,7 +15,7 @@ autorequire:
|
|
15
15
|
bindir: bin
|
16
16
|
cert_chain: []
|
17
17
|
|
18
|
-
date: 2010-08-
|
18
|
+
date: 2010-08-22 00:00:00 -04:00
|
19
19
|
default_executable:
|
20
20
|
dependencies:
|
21
21
|
- !ruby/object:Gem::Dependency
|