fb_graph 1.7.1 → 1.7.2
Sign up to get free protection for your applications and to get access to all the features.
- data/.gitignore +21 -0
- data/.rspec +2 -0
- data/Gemfile +2 -0
- data/Gemfile.lock +52 -0
- data/README.rdoc +1 -0
- data/Rakefile +8 -34
- data/VERSION +1 -1
- data/fb_graph.gemspec +15 -433
- data/lib/fb_graph/connections/family.rb +14 -0
- data/lib/fb_graph/connections/permissions.rb +12 -0
- data/lib/fb_graph/page/category_attributes.rb +1 -0
- data/lib/fb_graph/user.rb +4 -1
- data/lib/fb_graph.rb +0 -1
- data/spec/fb_graph/application_spec.rb +8 -14
- data/spec/fb_graph/auth_spec.rb +1 -1
- data/spec/fb_graph/checkin_spec.rb +15 -11
- data/spec/fb_graph/collection_spec.rb +8 -7
- data/spec/fb_graph/connection_spec.rb +36 -25
- data/spec/fb_graph/connections/accounts_spec.rb +30 -26
- data/spec/fb_graph/connections/activities_spec.rb +19 -18
- data/spec/fb_graph/connections/albums_spec.rb +40 -37
- data/spec/fb_graph/connections/app_requests_spec.rb +7 -7
- data/spec/fb_graph/connections/attending_spec.rb +12 -12
- data/spec/fb_graph/connections/books_spec.rb +18 -17
- data/spec/fb_graph/connections/checkins_spec.rb +91 -91
- data/spec/fb_graph/connections/comments_spec.rb +41 -48
- data/spec/fb_graph/connections/declined_spec.rb +13 -9
- data/spec/fb_graph/connections/events_spec.rb +31 -32
- data/spec/fb_graph/connections/family_spec.rb +34 -0
- data/spec/fb_graph/connections/feed_spec.rb +65 -70
- data/spec/fb_graph/connections/former_participants_spec.rb +8 -7
- data/spec/fb_graph/connections/friend_lists_spec.rb +7 -7
- data/spec/fb_graph/connections/friends_spec.rb +29 -24
- data/spec/fb_graph/connections/games_spec.rb +15 -15
- data/spec/fb_graph/connections/groups_spec.rb +17 -16
- data/spec/fb_graph/connections/home_spec.rb +40 -35
- data/spec/fb_graph/connections/insights_spec.rb +74 -70
- data/spec/fb_graph/connections/interests_spec.rb +7 -7
- data/spec/fb_graph/connections/invited_spec.rb +7 -7
- data/spec/fb_graph/connections/likes_spec.rb +23 -19
- data/spec/fb_graph/connections/links_spec.rb +17 -19
- data/spec/fb_graph/connections/maybe_spec.rb +10 -12
- data/spec/fb_graph/connections/members_spec.rb +7 -7
- data/spec/fb_graph/connections/messages_spec.rb +8 -7
- data/spec/fb_graph/connections/movies_spec.rb +7 -7
- data/spec/fb_graph/connections/music_spec.rb +7 -7
- data/spec/fb_graph/connections/noreply_spec.rb +7 -7
- data/spec/fb_graph/connections/notes_spec.rb +18 -16
- data/spec/fb_graph/connections/participants_spec.rb +8 -7
- data/spec/fb_graph/connections/permissions_spec.rb +18 -0
- data/spec/fb_graph/connections/photos_spec.rb +24 -24
- data/spec/fb_graph/connections/posts_spec.rb +23 -26
- data/spec/fb_graph/connections/senders_spec.rb +8 -7
- data/spec/fb_graph/connections/statuses_spec.rb +45 -43
- data/spec/fb_graph/connections/subscriptions_spec.rb +7 -7
- data/spec/fb_graph/connections/tagged_spec.rb +30 -33
- data/spec/fb_graph/connections/television_spec.rb +7 -7
- data/spec/fb_graph/connections/test_users_spec.rb +13 -9
- data/spec/fb_graph/connections/threads_spec.rb +7 -7
- data/spec/fb_graph/connections/videos_spec.rb +7 -7
- data/spec/fb_graph/page/local_business_spec.rb +4 -4
- data/spec/fb_graph/page/movie_spec.rb +4 -4
- data/spec/fb_graph/page/music_spec.rb +4 -4
- data/spec/fb_graph/page/person_spec.rb +4 -4
- data/spec/fb_graph/page/product_spec.rb +4 -4
- data/spec/fb_graph/page_spec.rb +8 -16
- data/spec/fb_graph/post_spec.rb +50 -46
- data/spec/fb_graph/query/core_spec.rb +39 -51
- data/spec/fb_graph/searchable_spec.rb +13 -9
- data/spec/fb_graph/test_user_spec.rb +5 -11
- data/spec/fb_graph/user_spec.rb +96 -91
- data/spec/helpers/webmock_helper.rb +71 -0
- data/spec/{fake_json → mock_json}/albums/photos/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/albums/photos/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/applications/feed/public.json +0 -0
- data/spec/{fake_json → mock_json}/applications/subscriptions/fb_graph_private.json +0 -0
- data/spec/{fake_json → mock_json}/applications/test_users/created.json +0 -0
- data/spec/{fake_json → mock_json}/applications/test_users/private.json +0 -0
- data/spec/{fake_json → mock_json}/checkins/search_private.json +0 -0
- data/spec/{fake_json → mock_json}/checkins/search_public.json +0 -0
- data/spec/{fake_json → mock_json}/events/attending/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/events/attending/smartday_private.json +0 -0
- data/spec/{fake_json → mock_json}/events/declined/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/events/declined/smartday_private.json +0 -0
- data/spec/{fake_json → mock_json}/events/invited/smartday_private.json +0 -0
- data/spec/{fake_json → mock_json}/events/maybe/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/events/maybe/smartday_private.json +0 -0
- data/spec/{fake_json → mock_json}/events/noreply/smartday_private.json +0 -0
- data/spec/{fake_json → mock_json}/groups/members/emacs_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/categories/local_business.json +0 -0
- data/spec/{fake_json → mock_json}/pages/categories/movie.json +0 -0
- data/spec/{fake_json → mock_json}/pages/categories/music.json +0 -0
- data/spec/{fake_json → mock_json}/pages/categories/person.json +0 -0
- data/spec/{fake_json → mock_json}/pages/categories/product.json +0 -0
- data/spec/{fake_json → mock_json}/pages/checkins/gowalla_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/checkins/gowalla_public.json +0 -0
- data/spec/{fake_json → mock_json}/pages/insights/FbGraph_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/insights/FbGraph_public.json +0 -0
- data/spec/{fake_json → mock_json}/pages/insights/page_like_adds/FbGraph_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/insights/page_like_adds/day/FbGraph_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/notes/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/pages/platform_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/platform_public.json +0 -0
- data/spec/{fake_json → mock_json}/pages/search_fb_graph.json +0 -0
- data/spec/{fake_json → mock_json}/pages/search_google.json +0 -0
- data/spec/{fake_json → mock_json}/pages/statuses/platform_private.json +0 -0
- data/spec/{fake_json → mock_json}/pages/statuses/platform_public.json +0 -0
- data/spec/{fake_json → mock_json}/posts/comments/post_with_invalid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/comments/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/comments/post_without_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/likes/post_with_invalid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/likes/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/likes/post_without_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/posts/no_comments.json +0 -0
- data/spec/{fake_json → mock_json}/posts/platform_private.json +0 -0
- data/spec/{fake_json → mock_json}/posts/platform_public.json +0 -0
- data/spec/{fake_json → mock_json}/posts/to_application.json +0 -0
- data/spec/{fake_json → mock_json}/posts/to_event.json +0 -0
- data/spec/{fake_json → mock_json}/posts/to_group.json +0 -0
- data/spec/{fake_json → mock_json}/query/user/with_invalid_token.json +0 -0
- data/spec/{fake_json → mock_json}/query/user/with_valid_token.json +0 -0
- data/spec/{fake_json → mock_json}/query/user/without_token.json +0 -0
- data/spec/{fake_json → mock_json}/statuses/with_likes.json +0 -0
- data/spec/{fake_json → mock_json}/thread/former_participants/private.json +0 -0
- data/spec/{fake_json → mock_json}/thread/messages/private.json +0 -0
- data/spec/{fake_json → mock_json}/thread/participants/private.json +0 -0
- data/spec/{fake_json → mock_json}/thread/senders/private.json +0 -0
- data/spec/{fake_json → mock_json}/token_response.json +0 -0
- data/spec/{fake_json → mock_json}/true.json +0 -0
- data/spec/{fake_json → mock_json}/users/accounts/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/accounts/matake_private_with_manage_pages_permission.json +0 -0
- data/spec/{fake_json → mock_json}/users/accounts/matake_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/activities/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/activities/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/albums/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/albums/matake_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/albums/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/users/app_requests/me_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/books/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/books/matake_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/checkins/mattt_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/checkins/mattt_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/checkins/posted.json +0 -0
- data/spec/{fake_json → mock_json}/users/events/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/events/matake_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/events/post_with_valid_access_token.json +0 -0
- data/spec/mock_json/users/family/family_without_access_token.json +6 -0
- data/spec/mock_json/users/family/me_public.json +19 -0
- data/spec/{fake_json → mock_json}/users/feed/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/feed/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/feed/post_with_invalid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/users/feed/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/users/feed/post_without_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/users/friend_lists/matake.json +0 -0
- data/spec/{fake_json → mock_json}/users/friends/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/friends/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/friends/me_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/friends/me_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/games/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/groups/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/groups/matake_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/me_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/me_private_next.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/me_private_previous.json +0 -0
- data/spec/{fake_json → mock_json}/users/home/me_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/interests/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/likes/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/likes/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/links/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/links/post_with_valid_access_token.json +0 -0
- data/spec/{fake_json → mock_json}/users/me_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/me_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/movies/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/music/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/notes/matake_private.json +0 -0
- data/spec/mock_json/users/permissions/me_private.json +70 -0
- data/spec/{fake_json → mock_json}/users/posts/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/posts/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/statuses/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/statuses/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/tagged/arjun_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/tagged/arjun_public.json +0 -0
- data/spec/{fake_json → mock_json}/users/television/matake_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/threads/me_private.json +0 -0
- data/spec/{fake_json → mock_json}/users/videos/kirk_private.json +0 -0
- data/spec/spec_helper.rb +2 -7
- metadata +267 -128
- data/.rspec-tm +0 -1
- data/spec/helpers/fake_json_helper.rb +0 -37
- data/spec/spec.opts +0 -3
metadata
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
name: fb_graph
|
3
3
|
version: !ruby/object:Gem::Version
|
4
4
|
prerelease:
|
5
|
-
version: 1.7.
|
5
|
+
version: 1.7.2
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
8
8
|
- nov matake
|
@@ -10,7 +10,7 @@ autorequire:
|
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
12
|
|
13
|
-
date: 2011-
|
13
|
+
date: 2011-05-01 00:00:00 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: rack-oauth2
|
@@ -24,14 +24,14 @@ dependencies:
|
|
24
24
|
type: :runtime
|
25
25
|
version_requirements: *id001
|
26
26
|
- !ruby/object:Gem::Dependency
|
27
|
-
name:
|
27
|
+
name: rake
|
28
28
|
prerelease: false
|
29
29
|
requirement: &id002 !ruby/object:Gem::Requirement
|
30
30
|
none: false
|
31
31
|
requirements:
|
32
|
-
- -
|
32
|
+
- - ">="
|
33
33
|
- !ruby/object:Gem::Version
|
34
|
-
version: "
|
34
|
+
version: "0.8"
|
35
35
|
type: :development
|
36
36
|
version_requirements: *id002
|
37
37
|
- !ruby/object:Gem::Dependency
|
@@ -42,20 +42,31 @@ dependencies:
|
|
42
42
|
requirements:
|
43
43
|
- - ">="
|
44
44
|
- !ruby/object:Gem::Version
|
45
|
-
version: "0"
|
45
|
+
version: "0.9"
|
46
46
|
type: :development
|
47
47
|
version_requirements: *id003
|
48
48
|
- !ruby/object:Gem::Dependency
|
49
|
-
name:
|
49
|
+
name: rspec
|
50
50
|
prerelease: false
|
51
51
|
requirement: &id004 !ruby/object:Gem::Requirement
|
52
52
|
none: false
|
53
53
|
requirements:
|
54
54
|
- - ">="
|
55
55
|
- !ruby/object:Gem::Version
|
56
|
-
version:
|
56
|
+
version: "2"
|
57
57
|
type: :development
|
58
58
|
version_requirements: *id004
|
59
|
+
- !ruby/object:Gem::Dependency
|
60
|
+
name: webmock
|
61
|
+
prerelease: false
|
62
|
+
requirement: &id005 !ruby/object:Gem::Requirement
|
63
|
+
none: false
|
64
|
+
requirements:
|
65
|
+
- - ">="
|
66
|
+
- !ruby/object:Gem::Version
|
67
|
+
version: 1.6.2
|
68
|
+
type: :development
|
69
|
+
version_requirements: *id005
|
59
70
|
description: A full-stack Facebook Graph API wrapper in Ruby.
|
60
71
|
email: nov@matake.jp
|
61
72
|
executables: []
|
@@ -67,7 +78,10 @@ extra_rdoc_files:
|
|
67
78
|
- README.rdoc
|
68
79
|
files:
|
69
80
|
- .document
|
70
|
-
- .
|
81
|
+
- .gitignore
|
82
|
+
- .rspec
|
83
|
+
- Gemfile
|
84
|
+
- Gemfile.lock
|
71
85
|
- LICENSE
|
72
86
|
- README.rdoc
|
73
87
|
- Rakefile
|
@@ -99,6 +113,7 @@ files:
|
|
99
113
|
- lib/fb_graph/connections/comments.rb
|
100
114
|
- lib/fb_graph/connections/declined.rb
|
101
115
|
- lib/fb_graph/connections/events.rb
|
116
|
+
- lib/fb_graph/connections/family.rb
|
102
117
|
- lib/fb_graph/connections/feed.rb
|
103
118
|
- lib/fb_graph/connections/former_participants.rb
|
104
119
|
- lib/fb_graph/connections/friend_lists.rb
|
@@ -120,6 +135,7 @@ files:
|
|
120
135
|
- lib/fb_graph/connections/notes.rb
|
121
136
|
- lib/fb_graph/connections/participants.rb
|
122
137
|
- lib/fb_graph/connections/payments.rb
|
138
|
+
- lib/fb_graph/connections/permissions.rb
|
123
139
|
- lib/fb_graph/connections/photos.rb
|
124
140
|
- lib/fb_graph/connections/picture.rb
|
125
141
|
- lib/fb_graph/connections/posts.rb
|
@@ -164,120 +180,6 @@ files:
|
|
164
180
|
- lib/fb_graph/venue.rb
|
165
181
|
- lib/fb_graph/video.rb
|
166
182
|
- lib/fb_graph/work.rb
|
167
|
-
- spec/fake_json/albums/photos/matake_private.json
|
168
|
-
- spec/fake_json/albums/photos/post_with_valid_access_token.json
|
169
|
-
- spec/fake_json/applications/feed/public.json
|
170
|
-
- spec/fake_json/applications/subscriptions/fb_graph_private.json
|
171
|
-
- spec/fake_json/applications/test_users/created.json
|
172
|
-
- spec/fake_json/applications/test_users/private.json
|
173
|
-
- spec/fake_json/checkins/search_private.json
|
174
|
-
- spec/fake_json/checkins/search_public.json
|
175
|
-
- spec/fake_json/events/attending/post_with_valid_access_token.json
|
176
|
-
- spec/fake_json/events/attending/smartday_private.json
|
177
|
-
- spec/fake_json/events/declined/post_with_valid_access_token.json
|
178
|
-
- spec/fake_json/events/declined/smartday_private.json
|
179
|
-
- spec/fake_json/events/invited/smartday_private.json
|
180
|
-
- spec/fake_json/events/maybe/post_with_valid_access_token.json
|
181
|
-
- spec/fake_json/events/maybe/smartday_private.json
|
182
|
-
- spec/fake_json/events/noreply/smartday_private.json
|
183
|
-
- spec/fake_json/groups/members/emacs_private.json
|
184
|
-
- spec/fake_json/pages/categories/local_business.json
|
185
|
-
- spec/fake_json/pages/categories/movie.json
|
186
|
-
- spec/fake_json/pages/categories/music.json
|
187
|
-
- spec/fake_json/pages/categories/person.json
|
188
|
-
- spec/fake_json/pages/categories/product.json
|
189
|
-
- spec/fake_json/pages/checkins/gowalla_private.json
|
190
|
-
- spec/fake_json/pages/checkins/gowalla_public.json
|
191
|
-
- spec/fake_json/pages/insights/FbGraph_private.json
|
192
|
-
- spec/fake_json/pages/insights/FbGraph_public.json
|
193
|
-
- spec/fake_json/pages/insights/page_like_adds/FbGraph_private.json
|
194
|
-
- spec/fake_json/pages/insights/page_like_adds/day/FbGraph_private.json
|
195
|
-
- spec/fake_json/pages/notes/post_with_valid_access_token.json
|
196
|
-
- spec/fake_json/pages/platform_private.json
|
197
|
-
- spec/fake_json/pages/platform_public.json
|
198
|
-
- spec/fake_json/pages/search_fb_graph.json
|
199
|
-
- spec/fake_json/pages/search_google.json
|
200
|
-
- spec/fake_json/pages/statuses/platform_private.json
|
201
|
-
- spec/fake_json/pages/statuses/platform_public.json
|
202
|
-
- spec/fake_json/posts/comments/post_with_invalid_access_token.json
|
203
|
-
- spec/fake_json/posts/comments/post_with_valid_access_token.json
|
204
|
-
- spec/fake_json/posts/comments/post_without_access_token.json
|
205
|
-
- spec/fake_json/posts/likes/post_with_invalid_access_token.json
|
206
|
-
- spec/fake_json/posts/likes/post_with_valid_access_token.json
|
207
|
-
- spec/fake_json/posts/likes/post_without_access_token.json
|
208
|
-
- spec/fake_json/posts/no_comments.json
|
209
|
-
- spec/fake_json/posts/platform_private.json
|
210
|
-
- spec/fake_json/posts/platform_public.json
|
211
|
-
- spec/fake_json/posts/to_application.json
|
212
|
-
- spec/fake_json/posts/to_event.json
|
213
|
-
- spec/fake_json/posts/to_group.json
|
214
|
-
- spec/fake_json/query/user/with_invalid_token.json
|
215
|
-
- spec/fake_json/query/user/with_valid_token.json
|
216
|
-
- spec/fake_json/query/user/without_token.json
|
217
|
-
- spec/fake_json/statuses/with_likes.json
|
218
|
-
- spec/fake_json/thread/former_participants/private.json
|
219
|
-
- spec/fake_json/thread/messages/private.json
|
220
|
-
- spec/fake_json/thread/participants/private.json
|
221
|
-
- spec/fake_json/thread/senders/private.json
|
222
|
-
- spec/fake_json/token_response.json
|
223
|
-
- spec/fake_json/true.json
|
224
|
-
- spec/fake_json/users/accounts/matake_private.json
|
225
|
-
- spec/fake_json/users/accounts/matake_private_with_manage_pages_permission.json
|
226
|
-
- spec/fake_json/users/accounts/matake_public.json
|
227
|
-
- spec/fake_json/users/activities/arjun_private.json
|
228
|
-
- spec/fake_json/users/activities/arjun_public.json
|
229
|
-
- spec/fake_json/users/albums/matake_private.json
|
230
|
-
- spec/fake_json/users/albums/matake_public.json
|
231
|
-
- spec/fake_json/users/albums/post_with_valid_access_token.json
|
232
|
-
- spec/fake_json/users/app_requests/me_private.json
|
233
|
-
- spec/fake_json/users/arjun_private.json
|
234
|
-
- spec/fake_json/users/arjun_public.json
|
235
|
-
- spec/fake_json/users/books/matake_private.json
|
236
|
-
- spec/fake_json/users/books/matake_public.json
|
237
|
-
- spec/fake_json/users/checkins/mattt_private.json
|
238
|
-
- spec/fake_json/users/checkins/mattt_public.json
|
239
|
-
- spec/fake_json/users/checkins/posted.json
|
240
|
-
- spec/fake_json/users/events/matake_private.json
|
241
|
-
- spec/fake_json/users/events/matake_public.json
|
242
|
-
- spec/fake_json/users/events/post_with_valid_access_token.json
|
243
|
-
- spec/fake_json/users/feed/arjun_private.json
|
244
|
-
- spec/fake_json/users/feed/arjun_public.json
|
245
|
-
- spec/fake_json/users/feed/post_with_invalid_access_token.json
|
246
|
-
- spec/fake_json/users/feed/post_with_valid_access_token.json
|
247
|
-
- spec/fake_json/users/feed/post_without_access_token.json
|
248
|
-
- spec/fake_json/users/friend_lists/matake.json
|
249
|
-
- spec/fake_json/users/friends/arjun_private.json
|
250
|
-
- spec/fake_json/users/friends/arjun_public.json
|
251
|
-
- spec/fake_json/users/friends/me_private.json
|
252
|
-
- spec/fake_json/users/friends/me_public.json
|
253
|
-
- spec/fake_json/users/games/matake_private.json
|
254
|
-
- spec/fake_json/users/groups/matake_private.json
|
255
|
-
- spec/fake_json/users/groups/matake_public.json
|
256
|
-
- spec/fake_json/users/home/arjun_private.json
|
257
|
-
- spec/fake_json/users/home/arjun_public.json
|
258
|
-
- spec/fake_json/users/home/me_private.json
|
259
|
-
- spec/fake_json/users/home/me_private_next.json
|
260
|
-
- spec/fake_json/users/home/me_private_previous.json
|
261
|
-
- spec/fake_json/users/home/me_public.json
|
262
|
-
- spec/fake_json/users/interests/matake_private.json
|
263
|
-
- spec/fake_json/users/likes/arjun_private.json
|
264
|
-
- spec/fake_json/users/likes/arjun_public.json
|
265
|
-
- spec/fake_json/users/links/matake_private.json
|
266
|
-
- spec/fake_json/users/links/post_with_valid_access_token.json
|
267
|
-
- spec/fake_json/users/me_private.json
|
268
|
-
- spec/fake_json/users/me_public.json
|
269
|
-
- spec/fake_json/users/movies/matake_private.json
|
270
|
-
- spec/fake_json/users/music/matake_private.json
|
271
|
-
- spec/fake_json/users/notes/matake_private.json
|
272
|
-
- spec/fake_json/users/posts/arjun_private.json
|
273
|
-
- spec/fake_json/users/posts/arjun_public.json
|
274
|
-
- spec/fake_json/users/statuses/arjun_private.json
|
275
|
-
- spec/fake_json/users/statuses/arjun_public.json
|
276
|
-
- spec/fake_json/users/tagged/arjun_private.json
|
277
|
-
- spec/fake_json/users/tagged/arjun_public.json
|
278
|
-
- spec/fake_json/users/television/matake_private.json
|
279
|
-
- spec/fake_json/users/threads/me_private.json
|
280
|
-
- spec/fake_json/users/videos/kirk_private.json
|
281
183
|
- spec/fb_graph/album_spec.rb
|
282
184
|
- spec/fb_graph/app_request_spec.rb
|
283
185
|
- spec/fb_graph/application_spec.rb
|
@@ -298,6 +200,7 @@ files:
|
|
298
200
|
- spec/fb_graph/connections/comments_spec.rb
|
299
201
|
- spec/fb_graph/connections/declined_spec.rb
|
300
202
|
- spec/fb_graph/connections/events_spec.rb
|
203
|
+
- spec/fb_graph/connections/family_spec.rb
|
301
204
|
- spec/fb_graph/connections/feed_spec.rb
|
302
205
|
- spec/fb_graph/connections/former_participants_spec.rb
|
303
206
|
- spec/fb_graph/connections/friend_lists_spec.rb
|
@@ -318,6 +221,7 @@ files:
|
|
318
221
|
- spec/fb_graph/connections/noreply_spec.rb
|
319
222
|
- spec/fb_graph/connections/notes_spec.rb
|
320
223
|
- spec/fb_graph/connections/participants_spec.rb
|
224
|
+
- spec/fb_graph/connections/permissions_spec.rb
|
321
225
|
- spec/fb_graph/connections/photos_spec.rb
|
322
226
|
- spec/fb_graph/connections/picture_spec.rb
|
323
227
|
- spec/fb_graph/connections/posts_spec.rb
|
@@ -364,15 +268,131 @@ files:
|
|
364
268
|
- spec/fb_graph/venue_spec.rb
|
365
269
|
- spec/fb_graph/video_spec.rb
|
366
270
|
- spec/fb_graph/work_spec.rb
|
367
|
-
- spec/helpers/
|
368
|
-
- spec/
|
271
|
+
- spec/helpers/webmock_helper.rb
|
272
|
+
- spec/mock_json/albums/photos/matake_private.json
|
273
|
+
- spec/mock_json/albums/photos/post_with_valid_access_token.json
|
274
|
+
- spec/mock_json/applications/feed/public.json
|
275
|
+
- spec/mock_json/applications/subscriptions/fb_graph_private.json
|
276
|
+
- spec/mock_json/applications/test_users/created.json
|
277
|
+
- spec/mock_json/applications/test_users/private.json
|
278
|
+
- spec/mock_json/checkins/search_private.json
|
279
|
+
- spec/mock_json/checkins/search_public.json
|
280
|
+
- spec/mock_json/events/attending/post_with_valid_access_token.json
|
281
|
+
- spec/mock_json/events/attending/smartday_private.json
|
282
|
+
- spec/mock_json/events/declined/post_with_valid_access_token.json
|
283
|
+
- spec/mock_json/events/declined/smartday_private.json
|
284
|
+
- spec/mock_json/events/invited/smartday_private.json
|
285
|
+
- spec/mock_json/events/maybe/post_with_valid_access_token.json
|
286
|
+
- spec/mock_json/events/maybe/smartday_private.json
|
287
|
+
- spec/mock_json/events/noreply/smartday_private.json
|
288
|
+
- spec/mock_json/groups/members/emacs_private.json
|
289
|
+
- spec/mock_json/pages/categories/local_business.json
|
290
|
+
- spec/mock_json/pages/categories/movie.json
|
291
|
+
- spec/mock_json/pages/categories/music.json
|
292
|
+
- spec/mock_json/pages/categories/person.json
|
293
|
+
- spec/mock_json/pages/categories/product.json
|
294
|
+
- spec/mock_json/pages/checkins/gowalla_private.json
|
295
|
+
- spec/mock_json/pages/checkins/gowalla_public.json
|
296
|
+
- spec/mock_json/pages/insights/FbGraph_private.json
|
297
|
+
- spec/mock_json/pages/insights/FbGraph_public.json
|
298
|
+
- spec/mock_json/pages/insights/page_like_adds/FbGraph_private.json
|
299
|
+
- spec/mock_json/pages/insights/page_like_adds/day/FbGraph_private.json
|
300
|
+
- spec/mock_json/pages/notes/post_with_valid_access_token.json
|
301
|
+
- spec/mock_json/pages/platform_private.json
|
302
|
+
- spec/mock_json/pages/platform_public.json
|
303
|
+
- spec/mock_json/pages/search_fb_graph.json
|
304
|
+
- spec/mock_json/pages/search_google.json
|
305
|
+
- spec/mock_json/pages/statuses/platform_private.json
|
306
|
+
- spec/mock_json/pages/statuses/platform_public.json
|
307
|
+
- spec/mock_json/posts/comments/post_with_invalid_access_token.json
|
308
|
+
- spec/mock_json/posts/comments/post_with_valid_access_token.json
|
309
|
+
- spec/mock_json/posts/comments/post_without_access_token.json
|
310
|
+
- spec/mock_json/posts/likes/post_with_invalid_access_token.json
|
311
|
+
- spec/mock_json/posts/likes/post_with_valid_access_token.json
|
312
|
+
- spec/mock_json/posts/likes/post_without_access_token.json
|
313
|
+
- spec/mock_json/posts/no_comments.json
|
314
|
+
- spec/mock_json/posts/platform_private.json
|
315
|
+
- spec/mock_json/posts/platform_public.json
|
316
|
+
- spec/mock_json/posts/to_application.json
|
317
|
+
- spec/mock_json/posts/to_event.json
|
318
|
+
- spec/mock_json/posts/to_group.json
|
319
|
+
- spec/mock_json/query/user/with_invalid_token.json
|
320
|
+
- spec/mock_json/query/user/with_valid_token.json
|
321
|
+
- spec/mock_json/query/user/without_token.json
|
322
|
+
- spec/mock_json/statuses/with_likes.json
|
323
|
+
- spec/mock_json/thread/former_participants/private.json
|
324
|
+
- spec/mock_json/thread/messages/private.json
|
325
|
+
- spec/mock_json/thread/participants/private.json
|
326
|
+
- spec/mock_json/thread/senders/private.json
|
327
|
+
- spec/mock_json/token_response.json
|
328
|
+
- spec/mock_json/true.json
|
329
|
+
- spec/mock_json/users/accounts/matake_private.json
|
330
|
+
- spec/mock_json/users/accounts/matake_private_with_manage_pages_permission.json
|
331
|
+
- spec/mock_json/users/accounts/matake_public.json
|
332
|
+
- spec/mock_json/users/activities/arjun_private.json
|
333
|
+
- spec/mock_json/users/activities/arjun_public.json
|
334
|
+
- spec/mock_json/users/albums/matake_private.json
|
335
|
+
- spec/mock_json/users/albums/matake_public.json
|
336
|
+
- spec/mock_json/users/albums/post_with_valid_access_token.json
|
337
|
+
- spec/mock_json/users/app_requests/me_private.json
|
338
|
+
- spec/mock_json/users/arjun_private.json
|
339
|
+
- spec/mock_json/users/arjun_public.json
|
340
|
+
- spec/mock_json/users/books/matake_private.json
|
341
|
+
- spec/mock_json/users/books/matake_public.json
|
342
|
+
- spec/mock_json/users/checkins/mattt_private.json
|
343
|
+
- spec/mock_json/users/checkins/mattt_public.json
|
344
|
+
- spec/mock_json/users/checkins/posted.json
|
345
|
+
- spec/mock_json/users/events/matake_private.json
|
346
|
+
- spec/mock_json/users/events/matake_public.json
|
347
|
+
- spec/mock_json/users/events/post_with_valid_access_token.json
|
348
|
+
- spec/mock_json/users/family/family_without_access_token.json
|
349
|
+
- spec/mock_json/users/family/me_public.json
|
350
|
+
- spec/mock_json/users/feed/arjun_private.json
|
351
|
+
- spec/mock_json/users/feed/arjun_public.json
|
352
|
+
- spec/mock_json/users/feed/post_with_invalid_access_token.json
|
353
|
+
- spec/mock_json/users/feed/post_with_valid_access_token.json
|
354
|
+
- spec/mock_json/users/feed/post_without_access_token.json
|
355
|
+
- spec/mock_json/users/friend_lists/matake.json
|
356
|
+
- spec/mock_json/users/friends/arjun_private.json
|
357
|
+
- spec/mock_json/users/friends/arjun_public.json
|
358
|
+
- spec/mock_json/users/friends/me_private.json
|
359
|
+
- spec/mock_json/users/friends/me_public.json
|
360
|
+
- spec/mock_json/users/games/matake_private.json
|
361
|
+
- spec/mock_json/users/groups/matake_private.json
|
362
|
+
- spec/mock_json/users/groups/matake_public.json
|
363
|
+
- spec/mock_json/users/home/arjun_private.json
|
364
|
+
- spec/mock_json/users/home/arjun_public.json
|
365
|
+
- spec/mock_json/users/home/me_private.json
|
366
|
+
- spec/mock_json/users/home/me_private_next.json
|
367
|
+
- spec/mock_json/users/home/me_private_previous.json
|
368
|
+
- spec/mock_json/users/home/me_public.json
|
369
|
+
- spec/mock_json/users/interests/matake_private.json
|
370
|
+
- spec/mock_json/users/likes/arjun_private.json
|
371
|
+
- spec/mock_json/users/likes/arjun_public.json
|
372
|
+
- spec/mock_json/users/links/matake_private.json
|
373
|
+
- spec/mock_json/users/links/post_with_valid_access_token.json
|
374
|
+
- spec/mock_json/users/me_private.json
|
375
|
+
- spec/mock_json/users/me_public.json
|
376
|
+
- spec/mock_json/users/movies/matake_private.json
|
377
|
+
- spec/mock_json/users/music/matake_private.json
|
378
|
+
- spec/mock_json/users/notes/matake_private.json
|
379
|
+
- spec/mock_json/users/permissions/me_private.json
|
380
|
+
- spec/mock_json/users/posts/arjun_private.json
|
381
|
+
- spec/mock_json/users/posts/arjun_public.json
|
382
|
+
- spec/mock_json/users/statuses/arjun_private.json
|
383
|
+
- spec/mock_json/users/statuses/arjun_public.json
|
384
|
+
- spec/mock_json/users/tagged/arjun_private.json
|
385
|
+
- spec/mock_json/users/tagged/arjun_public.json
|
386
|
+
- spec/mock_json/users/television/matake_private.json
|
387
|
+
- spec/mock_json/users/threads/me_private.json
|
388
|
+
- spec/mock_json/users/videos/kirk_private.json
|
369
389
|
- spec/spec_helper.rb
|
370
390
|
homepage: http://github.com/nov/fb_graph
|
371
391
|
licenses: []
|
372
392
|
|
373
393
|
post_install_message:
|
374
|
-
rdoc_options:
|
375
|
-
|
394
|
+
rdoc_options:
|
395
|
+
- --charset=UTF-8
|
376
396
|
require_paths:
|
377
397
|
- lib
|
378
398
|
required_ruby_version: !ruby/object:Gem::Requirement
|
@@ -415,6 +435,7 @@ test_files:
|
|
415
435
|
- spec/fb_graph/connections/comments_spec.rb
|
416
436
|
- spec/fb_graph/connections/declined_spec.rb
|
417
437
|
- spec/fb_graph/connections/events_spec.rb
|
438
|
+
- spec/fb_graph/connections/family_spec.rb
|
418
439
|
- spec/fb_graph/connections/feed_spec.rb
|
419
440
|
- spec/fb_graph/connections/former_participants_spec.rb
|
420
441
|
- spec/fb_graph/connections/friend_lists_spec.rb
|
@@ -435,6 +456,7 @@ test_files:
|
|
435
456
|
- spec/fb_graph/connections/noreply_spec.rb
|
436
457
|
- spec/fb_graph/connections/notes_spec.rb
|
437
458
|
- spec/fb_graph/connections/participants_spec.rb
|
459
|
+
- spec/fb_graph/connections/permissions_spec.rb
|
438
460
|
- spec/fb_graph/connections/photos_spec.rb
|
439
461
|
- spec/fb_graph/connections/picture_spec.rb
|
440
462
|
- spec/fb_graph/connections/posts_spec.rb
|
@@ -481,5 +503,122 @@ test_files:
|
|
481
503
|
- spec/fb_graph/venue_spec.rb
|
482
504
|
- spec/fb_graph/video_spec.rb
|
483
505
|
- spec/fb_graph/work_spec.rb
|
484
|
-
- spec/helpers/
|
506
|
+
- spec/helpers/webmock_helper.rb
|
507
|
+
- spec/mock_json/albums/photos/matake_private.json
|
508
|
+
- spec/mock_json/albums/photos/post_with_valid_access_token.json
|
509
|
+
- spec/mock_json/applications/feed/public.json
|
510
|
+
- spec/mock_json/applications/subscriptions/fb_graph_private.json
|
511
|
+
- spec/mock_json/applications/test_users/created.json
|
512
|
+
- spec/mock_json/applications/test_users/private.json
|
513
|
+
- spec/mock_json/checkins/search_private.json
|
514
|
+
- spec/mock_json/checkins/search_public.json
|
515
|
+
- spec/mock_json/events/attending/post_with_valid_access_token.json
|
516
|
+
- spec/mock_json/events/attending/smartday_private.json
|
517
|
+
- spec/mock_json/events/declined/post_with_valid_access_token.json
|
518
|
+
- spec/mock_json/events/declined/smartday_private.json
|
519
|
+
- spec/mock_json/events/invited/smartday_private.json
|
520
|
+
- spec/mock_json/events/maybe/post_with_valid_access_token.json
|
521
|
+
- spec/mock_json/events/maybe/smartday_private.json
|
522
|
+
- spec/mock_json/events/noreply/smartday_private.json
|
523
|
+
- spec/mock_json/groups/members/emacs_private.json
|
524
|
+
- spec/mock_json/pages/categories/local_business.json
|
525
|
+
- spec/mock_json/pages/categories/movie.json
|
526
|
+
- spec/mock_json/pages/categories/music.json
|
527
|
+
- spec/mock_json/pages/categories/person.json
|
528
|
+
- spec/mock_json/pages/categories/product.json
|
529
|
+
- spec/mock_json/pages/checkins/gowalla_private.json
|
530
|
+
- spec/mock_json/pages/checkins/gowalla_public.json
|
531
|
+
- spec/mock_json/pages/insights/FbGraph_private.json
|
532
|
+
- spec/mock_json/pages/insights/FbGraph_public.json
|
533
|
+
- spec/mock_json/pages/insights/page_like_adds/FbGraph_private.json
|
534
|
+
- spec/mock_json/pages/insights/page_like_adds/day/FbGraph_private.json
|
535
|
+
- spec/mock_json/pages/notes/post_with_valid_access_token.json
|
536
|
+
- spec/mock_json/pages/platform_private.json
|
537
|
+
- spec/mock_json/pages/platform_public.json
|
538
|
+
- spec/mock_json/pages/search_fb_graph.json
|
539
|
+
- spec/mock_json/pages/search_google.json
|
540
|
+
- spec/mock_json/pages/statuses/platform_private.json
|
541
|
+
- spec/mock_json/pages/statuses/platform_public.json
|
542
|
+
- spec/mock_json/posts/comments/post_with_invalid_access_token.json
|
543
|
+
- spec/mock_json/posts/comments/post_with_valid_access_token.json
|
544
|
+
- spec/mock_json/posts/comments/post_without_access_token.json
|
545
|
+
- spec/mock_json/posts/likes/post_with_invalid_access_token.json
|
546
|
+
- spec/mock_json/posts/likes/post_with_valid_access_token.json
|
547
|
+
- spec/mock_json/posts/likes/post_without_access_token.json
|
548
|
+
- spec/mock_json/posts/no_comments.json
|
549
|
+
- spec/mock_json/posts/platform_private.json
|
550
|
+
- spec/mock_json/posts/platform_public.json
|
551
|
+
- spec/mock_json/posts/to_application.json
|
552
|
+
- spec/mock_json/posts/to_event.json
|
553
|
+
- spec/mock_json/posts/to_group.json
|
554
|
+
- spec/mock_json/query/user/with_invalid_token.json
|
555
|
+
- spec/mock_json/query/user/with_valid_token.json
|
556
|
+
- spec/mock_json/query/user/without_token.json
|
557
|
+
- spec/mock_json/statuses/with_likes.json
|
558
|
+
- spec/mock_json/thread/former_participants/private.json
|
559
|
+
- spec/mock_json/thread/messages/private.json
|
560
|
+
- spec/mock_json/thread/participants/private.json
|
561
|
+
- spec/mock_json/thread/senders/private.json
|
562
|
+
- spec/mock_json/token_response.json
|
563
|
+
- spec/mock_json/true.json
|
564
|
+
- spec/mock_json/users/accounts/matake_private.json
|
565
|
+
- spec/mock_json/users/accounts/matake_private_with_manage_pages_permission.json
|
566
|
+
- spec/mock_json/users/accounts/matake_public.json
|
567
|
+
- spec/mock_json/users/activities/arjun_private.json
|
568
|
+
- spec/mock_json/users/activities/arjun_public.json
|
569
|
+
- spec/mock_json/users/albums/matake_private.json
|
570
|
+
- spec/mock_json/users/albums/matake_public.json
|
571
|
+
- spec/mock_json/users/albums/post_with_valid_access_token.json
|
572
|
+
- spec/mock_json/users/app_requests/me_private.json
|
573
|
+
- spec/mock_json/users/arjun_private.json
|
574
|
+
- spec/mock_json/users/arjun_public.json
|
575
|
+
- spec/mock_json/users/books/matake_private.json
|
576
|
+
- spec/mock_json/users/books/matake_public.json
|
577
|
+
- spec/mock_json/users/checkins/mattt_private.json
|
578
|
+
- spec/mock_json/users/checkins/mattt_public.json
|
579
|
+
- spec/mock_json/users/checkins/posted.json
|
580
|
+
- spec/mock_json/users/events/matake_private.json
|
581
|
+
- spec/mock_json/users/events/matake_public.json
|
582
|
+
- spec/mock_json/users/events/post_with_valid_access_token.json
|
583
|
+
- spec/mock_json/users/family/family_without_access_token.json
|
584
|
+
- spec/mock_json/users/family/me_public.json
|
585
|
+
- spec/mock_json/users/feed/arjun_private.json
|
586
|
+
- spec/mock_json/users/feed/arjun_public.json
|
587
|
+
- spec/mock_json/users/feed/post_with_invalid_access_token.json
|
588
|
+
- spec/mock_json/users/feed/post_with_valid_access_token.json
|
589
|
+
- spec/mock_json/users/feed/post_without_access_token.json
|
590
|
+
- spec/mock_json/users/friend_lists/matake.json
|
591
|
+
- spec/mock_json/users/friends/arjun_private.json
|
592
|
+
- spec/mock_json/users/friends/arjun_public.json
|
593
|
+
- spec/mock_json/users/friends/me_private.json
|
594
|
+
- spec/mock_json/users/friends/me_public.json
|
595
|
+
- spec/mock_json/users/games/matake_private.json
|
596
|
+
- spec/mock_json/users/groups/matake_private.json
|
597
|
+
- spec/mock_json/users/groups/matake_public.json
|
598
|
+
- spec/mock_json/users/home/arjun_private.json
|
599
|
+
- spec/mock_json/users/home/arjun_public.json
|
600
|
+
- spec/mock_json/users/home/me_private.json
|
601
|
+
- spec/mock_json/users/home/me_private_next.json
|
602
|
+
- spec/mock_json/users/home/me_private_previous.json
|
603
|
+
- spec/mock_json/users/home/me_public.json
|
604
|
+
- spec/mock_json/users/interests/matake_private.json
|
605
|
+
- spec/mock_json/users/likes/arjun_private.json
|
606
|
+
- spec/mock_json/users/likes/arjun_public.json
|
607
|
+
- spec/mock_json/users/links/matake_private.json
|
608
|
+
- spec/mock_json/users/links/post_with_valid_access_token.json
|
609
|
+
- spec/mock_json/users/me_private.json
|
610
|
+
- spec/mock_json/users/me_public.json
|
611
|
+
- spec/mock_json/users/movies/matake_private.json
|
612
|
+
- spec/mock_json/users/music/matake_private.json
|
613
|
+
- spec/mock_json/users/notes/matake_private.json
|
614
|
+
- spec/mock_json/users/permissions/me_private.json
|
615
|
+
- spec/mock_json/users/posts/arjun_private.json
|
616
|
+
- spec/mock_json/users/posts/arjun_public.json
|
617
|
+
- spec/mock_json/users/statuses/arjun_private.json
|
618
|
+
- spec/mock_json/users/statuses/arjun_public.json
|
619
|
+
- spec/mock_json/users/tagged/arjun_private.json
|
620
|
+
- spec/mock_json/users/tagged/arjun_public.json
|
621
|
+
- spec/mock_json/users/television/matake_private.json
|
622
|
+
- spec/mock_json/users/threads/me_private.json
|
623
|
+
- spec/mock_json/users/videos/kirk_private.json
|
485
624
|
- spec/spec_helper.rb
|
data/.rspec-tm
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
--rspec-version 1.3
|
@@ -1,37 +0,0 @@
|
|
1
|
-
module FakeJsonHelper
|
2
|
-
|
3
|
-
def fake_json(method, path, file_path, options = {})
|
4
|
-
FakeWeb.register_uri(
|
5
|
-
method,
|
6
|
-
File.join(FbGraph::ROOT_URL, path),
|
7
|
-
options.merge(
|
8
|
-
:body => File.read(File.join(File.dirname(__FILE__), '../fake_json', "#{file_path}.json"))
|
9
|
-
)
|
10
|
-
)
|
11
|
-
end
|
12
|
-
|
13
|
-
def request_to(path, method = :get)
|
14
|
-
endpoint = File.join(FbGraph::ROOT_URL, path)
|
15
|
-
raise_error(
|
16
|
-
FakeWeb::NetConnectNotAllowedError,
|
17
|
-
"Real HTTP connections are disabled. Unregistered request: #{method.to_s.upcase} #{endpoint}"
|
18
|
-
)
|
19
|
-
end
|
20
|
-
|
21
|
-
def fake_fql_json(query, file_path, options = {})
|
22
|
-
params = {
|
23
|
-
:query => query,
|
24
|
-
:access_token => options[:access_token],
|
25
|
-
:format => :json
|
26
|
-
}
|
27
|
-
params.delete_if do |k, v|
|
28
|
-
v.blank?
|
29
|
-
end
|
30
|
-
FakeWeb.register_uri(
|
31
|
-
:get,
|
32
|
-
FbGraph::Query::ENDPOINT + '?' + params.to_query,
|
33
|
-
:body => File.read(File.join(File.dirname(__FILE__), '../fake_json', "#{file_path}.json"))
|
34
|
-
)
|
35
|
-
end
|
36
|
-
|
37
|
-
end
|
data/spec/spec.opts
DELETED