twitter 5.0.0.rc.1 → 5.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (102) hide show
  1. data.tar.gz.sig +0 -0
  2. data/CHANGELOG.md +7 -1
  3. data/CONTRIBUTING.md +13 -15
  4. data/README.md +53 -33
  5. data/Rakefile +6 -0
  6. data/lib/twitter/arguments.rb +3 -0
  7. data/lib/twitter/base.rb +88 -89
  8. data/lib/twitter/client.rb +5 -41
  9. data/lib/twitter/configuration.rb +4 -5
  10. data/lib/twitter/core_ext/kernel.rb +5 -1
  11. data/lib/twitter/creatable.rb +6 -1
  12. data/lib/twitter/cursor.rb +16 -12
  13. data/lib/twitter/entity/uri.rb +2 -1
  14. data/lib/twitter/enumerable.rb +1 -1
  15. data/lib/twitter/error.rb +42 -39
  16. data/lib/twitter/factory.rb +12 -5
  17. data/lib/twitter/geo.rb +2 -7
  18. data/lib/twitter/geo_factory.rb +11 -7
  19. data/lib/twitter/geo_results.rb +12 -8
  20. data/lib/twitter/identity.rb +4 -12
  21. data/lib/twitter/list.rb +6 -3
  22. data/lib/twitter/media/photo.rb +5 -3
  23. data/lib/twitter/media_factory.rb +11 -7
  24. data/lib/twitter/null_object.rb +4 -3
  25. data/lib/twitter/place.rb +10 -16
  26. data/lib/twitter/profile_banner.rb +4 -5
  27. data/lib/twitter/rate_limit.rb +3 -0
  28. data/lib/twitter/relationship.rb +0 -9
  29. data/lib/twitter/rest/api/direct_messages.rb +9 -6
  30. data/lib/twitter/rest/api/favorites.rb +6 -11
  31. data/lib/twitter/rest/api/friends_and_followers.rb +6 -9
  32. data/lib/twitter/rest/api/lists.rb +27 -20
  33. data/lib/twitter/rest/api/oauth.rb +17 -0
  34. data/lib/twitter/rest/api/places_and_geo.rb +0 -18
  35. data/lib/twitter/rest/api/saved_searches.rb +6 -4
  36. data/lib/twitter/rest/api/suggested_users.rb +2 -2
  37. data/lib/twitter/rest/api/tweets.rb +7 -9
  38. data/lib/twitter/rest/api/users.rb +6 -6
  39. data/lib/twitter/rest/api/utils.rb +44 -17
  40. data/lib/twitter/rest/client.rb +25 -43
  41. data/lib/twitter/rest/response/parse_error_json.rb +15 -0
  42. data/lib/twitter/rest/response/parse_json.rb +5 -1
  43. data/lib/twitter/search_results.rb +12 -8
  44. data/lib/twitter/size.rb +2 -15
  45. data/lib/twitter/streaming/client.rb +23 -11
  46. data/lib/twitter/streaming/event.rb +35 -0
  47. data/lib/twitter/streaming/friend_list.rb +13 -0
  48. data/lib/twitter/streaming/message_parser.rb +18 -0
  49. data/lib/twitter/streaming/response.rb +4 -0
  50. data/lib/twitter/suggestion.rb +5 -10
  51. data/lib/twitter/token.rb +3 -1
  52. data/lib/twitter/trend.rb +2 -7
  53. data/lib/twitter/trend_results.rb +20 -14
  54. data/lib/twitter/tweet.rb +18 -23
  55. data/lib/twitter/user.rb +34 -19
  56. data/lib/twitter/version.rb +1 -1
  57. data/spec/fixtures/request_token.txt +6 -0
  58. data/spec/fixtures/track_streaming_user.json +5 -0
  59. data/spec/twitter/base_spec.rb +0 -16
  60. data/spec/twitter/basic_user_spec.rb +3 -3
  61. data/spec/twitter/cursor_spec.rb +4 -4
  62. data/spec/twitter/direct_message_spec.rb +9 -9
  63. data/spec/twitter/entity/uri_spec.rb +12 -11
  64. data/spec/twitter/geo/point_spec.rb +5 -5
  65. data/spec/twitter/geo/polygon_spec.rb +5 -5
  66. data/spec/twitter/geo_factory_spec.rb +2 -2
  67. data/spec/twitter/geo_spec.rb +6 -6
  68. data/spec/twitter/identifiable_spec.rb +5 -5
  69. data/spec/twitter/list_spec.rb +7 -7
  70. data/spec/twitter/media/photo_spec.rb +19 -18
  71. data/spec/twitter/media_factory_spec.rb +2 -2
  72. data/spec/twitter/null_object_spec.rb +7 -6
  73. data/spec/twitter/oembed_spec.rb +6 -6
  74. data/spec/twitter/place_spec.rb +37 -37
  75. data/spec/twitter/rate_limit_spec.rb +0 -17
  76. data/spec/twitter/relationship_spec.rb +4 -12
  77. data/spec/twitter/rest/api/direct_messages_spec.rb +8 -8
  78. data/spec/twitter/rest/api/friends_and_followers_spec.rb +50 -120
  79. data/spec/twitter/rest/api/geo_spec.rb +0 -14
  80. data/spec/twitter/rest/api/lists_spec.rb +39 -39
  81. data/spec/twitter/rest/api/oauth_spec.rb +15 -4
  82. data/spec/twitter/rest/api/saved_searches_spec.rb +6 -6
  83. data/spec/twitter/rest/api/tweets_spec.rb +6 -6
  84. data/spec/twitter/rest/api/users_spec.rb +4 -4
  85. data/spec/twitter/rest/client_spec.rb +9 -9
  86. data/spec/twitter/saved_search_spec.rb +5 -5
  87. data/spec/twitter/search_results_spec.rb +3 -3
  88. data/spec/twitter/settings_spec.rb +2 -2
  89. data/spec/twitter/size_spec.rb +5 -15
  90. data/spec/twitter/source_user_spec.rb +3 -3
  91. data/spec/twitter/streaming/client_spec.rb +33 -16
  92. data/spec/twitter/streaming/event_spec.rb +45 -0
  93. data/spec/twitter/suggestion_spec.rb +5 -15
  94. data/spec/twitter/target_user_spec.rb +3 -3
  95. data/spec/twitter/token_spec.rb +2 -2
  96. data/spec/twitter/trend_results_spec.rb +6 -6
  97. data/spec/twitter/trend_spec.rb +7 -17
  98. data/spec/twitter/tweet_spec.rb +31 -25
  99. data/spec/twitter/user_spec.rb +16 -16
  100. data/twitter.gemspec +5 -2
  101. metadata +67 -15
  102. metadata.gz.sig +0 -0
@@ -1,16 +1,19 @@
1
- # coding: utf-8
2
1
  lib = File.expand_path('../lib', __FILE__)
3
2
  $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
3
  require 'twitter/version'
5
4
 
6
5
  Gem::Specification.new do |spec|
7
6
  spec.add_dependency 'buftok', '~> 0.1.0'
7
+ spec.add_dependency 'descendants_tracker', '~> 0.0.1'
8
+ spec.add_dependency 'equalizer', '~> 0.0.7'
8
9
  spec.add_dependency 'faraday', ['>= 0.8', '< 0.10']
9
- spec.add_dependency 'http', ['>= 0.5.0.pre2', '< 0.6']
10
+ spec.add_dependency 'http', '~> 0.5.0'
10
11
  spec.add_dependency 'http_parser.rb', '~> 0.5.0'
11
12
  spec.add_dependency 'json', '~> 1.8'
13
+ spec.add_dependency 'memoizable', '~> 0.2.0'
12
14
  spec.add_dependency 'simple_oauth', '~> 0.2.0'
13
15
  spec.add_development_dependency 'bundler', '~> 1.0'
16
+ spec.date = "2013-11-18"
14
17
  spec.authors = ["Erik Michaels-Ober", "John Nunemaker", "Wynn Netherland", "Steve Richert", "Steve Agalloco"]
15
18
  spec.cert_chain = ['certs/sferik.pem']
16
19
  spec.description = %q{A Ruby interface to the Twitter API.}
metadata CHANGED
@@ -1,8 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: twitter
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.0.rc.1
5
- prerelease: 6
4
+ version: 5.0.0
5
+ prerelease:
6
6
  platform: ruby
7
7
  authors:
8
8
  - Erik Michaels-Ober
@@ -40,7 +40,7 @@ cert_chain:
40
40
  U0xxV3ZRUnNCbHlwSGZoczZKSnVMbHlaUEdoVTNSL3YKU2YzbFZLcEJDV2dS
41
41
  cEdUdnk0NVhWcEIrNTl5MzNQSm1FdVExUFRFT1l2UXlhbzlVS01BQWFBTi83
42
42
  cVdRdGpsMApobHc9Ci0tLS0tRU5EIENFUlRJRklDQVRFLS0tLS0K
43
- date: 2013-09-12 00:00:00.000000000 Z
43
+ date: 2013-11-18 00:00:00.000000000 Z
44
44
  dependencies:
45
45
  - !ruby/object:Gem::Dependency
46
46
  name: buftok
@@ -58,6 +58,38 @@ dependencies:
58
58
  - - ~>
59
59
  - !ruby/object:Gem::Version
60
60
  version: 0.1.0
61
+ - !ruby/object:Gem::Dependency
62
+ name: descendants_tracker
63
+ requirement: !ruby/object:Gem::Requirement
64
+ none: false
65
+ requirements:
66
+ - - ~>
67
+ - !ruby/object:Gem::Version
68
+ version: 0.0.1
69
+ type: :runtime
70
+ prerelease: false
71
+ version_requirements: !ruby/object:Gem::Requirement
72
+ none: false
73
+ requirements:
74
+ - - ~>
75
+ - !ruby/object:Gem::Version
76
+ version: 0.0.1
77
+ - !ruby/object:Gem::Dependency
78
+ name: equalizer
79
+ requirement: !ruby/object:Gem::Requirement
80
+ none: false
81
+ requirements:
82
+ - - ~>
83
+ - !ruby/object:Gem::Version
84
+ version: 0.0.7
85
+ type: :runtime
86
+ prerelease: false
87
+ version_requirements: !ruby/object:Gem::Requirement
88
+ none: false
89
+ requirements:
90
+ - - ~>
91
+ - !ruby/object:Gem::Version
92
+ version: 0.0.7
61
93
  - !ruby/object:Gem::Dependency
62
94
  name: faraday
63
95
  requirement: !ruby/object:Gem::Requirement
@@ -85,23 +117,17 @@ dependencies:
85
117
  requirement: !ruby/object:Gem::Requirement
86
118
  none: false
87
119
  requirements:
88
- - - ! '>='
89
- - !ruby/object:Gem::Version
90
- version: 0.5.0.pre2
91
- - - <
120
+ - - ~>
92
121
  - !ruby/object:Gem::Version
93
- version: '0.6'
122
+ version: 0.5.0
94
123
  type: :runtime
95
124
  prerelease: false
96
125
  version_requirements: !ruby/object:Gem::Requirement
97
126
  none: false
98
127
  requirements:
99
- - - ! '>='
100
- - !ruby/object:Gem::Version
101
- version: 0.5.0.pre2
102
- - - <
128
+ - - ~>
103
129
  - !ruby/object:Gem::Version
104
- version: '0.6'
130
+ version: 0.5.0
105
131
  - !ruby/object:Gem::Dependency
106
132
  name: http_parser.rb
107
133
  requirement: !ruby/object:Gem::Requirement
@@ -134,6 +160,22 @@ dependencies:
134
160
  - - ~>
135
161
  - !ruby/object:Gem::Version
136
162
  version: '1.8'
163
+ - !ruby/object:Gem::Dependency
164
+ name: memoizable
165
+ requirement: !ruby/object:Gem::Requirement
166
+ none: false
167
+ requirements:
168
+ - - ~>
169
+ - !ruby/object:Gem::Version
170
+ version: 0.2.0
171
+ type: :runtime
172
+ prerelease: false
173
+ version_requirements: !ruby/object:Gem::Requirement
174
+ none: false
175
+ requirements:
176
+ - - ~>
177
+ - !ruby/object:Gem::Version
178
+ version: 0.2.0
137
179
  - !ruby/object:Gem::Dependency
138
180
  name: simple_oauth
139
181
  requirement: !ruby/object:Gem::Requirement
@@ -249,6 +291,7 @@ files:
249
291
  - lib/twitter/rest/api/utils.rb
250
292
  - lib/twitter/rest/client.rb
251
293
  - lib/twitter/rest/request/multipart_with_file.rb
294
+ - lib/twitter/rest/response/parse_error_json.rb
252
295
  - lib/twitter/rest/response/parse_json.rb
253
296
  - lib/twitter/rest/response/raise_error.rb
254
297
  - lib/twitter/saved_search.rb
@@ -258,6 +301,9 @@ files:
258
301
  - lib/twitter/source_user.rb
259
302
  - lib/twitter/streaming/client.rb
260
303
  - lib/twitter/streaming/connection.rb
304
+ - lib/twitter/streaming/event.rb
305
+ - lib/twitter/streaming/friend_list.rb
306
+ - lib/twitter/streaming/message_parser.rb
261
307
  - lib/twitter/streaming/response.rb
262
308
  - lib/twitter/suggestion.rb
263
309
  - lib/twitter/target_user.rb
@@ -307,6 +353,7 @@ files:
307
353
  - spec/fixtures/places.json
308
354
  - spec/fixtures/privacy.json
309
355
  - spec/fixtures/profile_banner.json
356
+ - spec/fixtures/request_token.txt
310
357
  - spec/fixtures/retweet.json
311
358
  - spec/fixtures/retweets.json
312
359
  - spec/fixtures/saved_search.json
@@ -322,6 +369,7 @@ files:
322
369
  - spec/fixtures/suggestions.json
323
370
  - spec/fixtures/tos.json
324
371
  - spec/fixtures/track_streaming.json
372
+ - spec/fixtures/track_streaming_user.json
325
373
  - spec/fixtures/user_search.json
326
374
  - spec/fixtures/user_timeline.json
327
375
  - spec/fixtures/users.json
@@ -375,6 +423,7 @@ files:
375
423
  - spec/twitter/size_spec.rb
376
424
  - spec/twitter/source_user_spec.rb
377
425
  - spec/twitter/streaming/client_spec.rb
426
+ - spec/twitter/streaming/event_spec.rb
378
427
  - spec/twitter/suggestion_spec.rb
379
428
  - spec/twitter/target_user_spec.rb
380
429
  - spec/twitter/token_spec.rb
@@ -399,9 +448,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
399
448
  required_rubygems_version: !ruby/object:Gem::Requirement
400
449
  none: false
401
450
  requirements:
402
- - - ! '>'
451
+ - - ! '>='
403
452
  - !ruby/object:Gem::Version
404
- version: 1.3.1
453
+ version: 1.3.5
405
454
  requirements: []
406
455
  rubyforge_project:
407
456
  rubygems_version: 1.8.23
@@ -448,6 +497,7 @@ test_files:
448
497
  - spec/fixtures/places.json
449
498
  - spec/fixtures/privacy.json
450
499
  - spec/fixtures/profile_banner.json
500
+ - spec/fixtures/request_token.txt
451
501
  - spec/fixtures/retweet.json
452
502
  - spec/fixtures/retweets.json
453
503
  - spec/fixtures/saved_search.json
@@ -463,6 +513,7 @@ test_files:
463
513
  - spec/fixtures/suggestions.json
464
514
  - spec/fixtures/tos.json
465
515
  - spec/fixtures/track_streaming.json
516
+ - spec/fixtures/track_streaming_user.json
466
517
  - spec/fixtures/user_search.json
467
518
  - spec/fixtures/user_timeline.json
468
519
  - spec/fixtures/users.json
@@ -516,6 +567,7 @@ test_files:
516
567
  - spec/twitter/size_spec.rb
517
568
  - spec/twitter/source_user_spec.rb
518
569
  - spec/twitter/streaming/client_spec.rb
570
+ - spec/twitter/streaming/event_spec.rb
519
571
  - spec/twitter/suggestion_spec.rb
520
572
  - spec/twitter/target_user_spec.rb
521
573
  - spec/twitter/token_spec.rb
metadata.gz.sig CHANGED
Binary file