bhauman-twroute 0.1.8 → 0.1.9
Sign up to get free protection for your applications and to get access to all the features.
- data/VERSION +1 -1
- data/lib/twroute/polling_search.rb +4 -2
- data/test/polling_search_test.rb +2 -0
- data/twroute.gemspec +1 -1
- metadata +2 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.1.
|
1
|
+
0.1.9
|
@@ -36,8 +36,10 @@ module Twroute
|
|
36
36
|
def send_query
|
37
37
|
results = Yajl::HttpStream.get( twitter_search_uri,
|
38
38
|
:symbolize_keys => true)
|
39
|
-
|
40
|
-
results
|
39
|
+
results = results[:results] || []
|
40
|
+
results.reverse!
|
41
|
+
@since_id = results.last[:id]
|
42
|
+
results.each do |tweet|
|
41
43
|
changed
|
42
44
|
notify_observers( tweet )
|
43
45
|
end
|
data/test/polling_search_test.rb
CHANGED
@@ -43,6 +43,8 @@ class PollingSearchTest < Test::Unit::TestCase
|
|
43
43
|
@tweeter.since_id.should == @listen.results.last[:id]
|
44
44
|
@tweeter.twitter_search_uri.to_s.should == "http://bhauman:watertank@search.twitter.com/search.json?q=twitter&rpp=20&since_id=#{@listen.results.last[:id]}"
|
45
45
|
|
46
|
+
@listen.results.first[:id].should <= @listen.results.last[:id]
|
47
|
+
|
46
48
|
end
|
47
49
|
|
48
50
|
end
|
data/twroute.gemspec
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bhauman-twroute
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.9
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- bhauman
|
@@ -172,7 +172,6 @@ files:
|
|
172
172
|
- twroute.gemspec
|
173
173
|
has_rdoc: true
|
174
174
|
homepage: http://github.com/bhauman/twroute
|
175
|
-
licenses:
|
176
175
|
post_install_message:
|
177
176
|
rdoc_options:
|
178
177
|
- --charset=UTF-8
|
@@ -193,7 +192,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
193
192
|
requirements: []
|
194
193
|
|
195
194
|
rubyforge_project:
|
196
|
-
rubygems_version: 1.
|
195
|
+
rubygems_version: 1.2.0
|
197
196
|
signing_key:
|
198
197
|
specification_version: 2
|
199
198
|
summary: Twroute listens for Twitter updates and redirects them to HTTP post requests
|